I want to get all classes that implement the IFeature
Interface. Java Refelctions appear to be a possible solution, but it doesn't work the way I want it to.
IFeature feature = new Landing();
Class<?>[] cls = Character.class.getInterfaces();
for(Class<?> c : cls ){
System.out.println(c.toString());
}
the output
run:
interface java.io.Serializable
interface java.lang.Comparable
BUILD SUCCESSFUL (total time: 0 seconds)
my interface...
public interface IFeature {
public abstract void update(HashMap<QueueIdentifier, Queue<Measurement>> messageMap);
public abstract List<QueueIdentifier> getQIdList();
public abstract int getCountSamples();
}
The soluton is the
ClassPathLoader
from the apache atn library. Here my code...