`Unable to find class` error in Drools

ahmad696

New Member
I'm trying to define a very simple function in \[code\]Drools\[/code\] as below:\[code\]import java.util.List;function int sumLengths(List<String> strings) { int counter = 0; for (String s : strings) counter += s.length(); return counter;}\[/code\]but it gives me error:\[code\]Exception in thread "main" java.lang.RuntimeException: [ function sumLengths (line:5):Unable to resolve type List<String> while building function. java.lang.ClassNotFoundException: Unable to find class 'List<String>' ]\[/code\]any idea?
 
Top