diff options
Diffstat (limited to 'sources/utils')
| -rw-r--r-- | sources/utils/VSClassLoader.java | 4 | ||||
| -rw-r--r-- | sources/utils/VSPriorityQueue.java | 15 |
2 files changed, 16 insertions, 3 deletions
diff --git a/sources/utils/VSClassLoader.java b/sources/utils/VSClassLoader.java index 8470f53..3e1611b 100644 --- a/sources/utils/VSClassLoader.java +++ b/sources/utils/VSClassLoader.java @@ -12,11 +12,9 @@ public class VSClassLoader extends ClassLoader { try { object = super.loadClass(classname, true).newInstance(); - //Constructor constructors[] = theClass.getConstructors(); - //object = constructors[0].newInstance(process); } catch (Exception e) { - System.out.println(e); + System.out.println(e + "; Classname " + classname); } return object; diff --git a/sources/utils/VSPriorityQueue.java b/sources/utils/VSPriorityQueue.java new file mode 100644 index 0000000..dd46a6e --- /dev/null +++ b/sources/utils/VSPriorityQueue.java @@ -0,0 +1,15 @@ +package utils; + +import java.util.PriorityQueue; + +public final class VSPriorityQueue<T> extends PriorityQueue<T> { + public T get(int index) { + int i = 0; + + for (T t : this) + if (i++ == index) + return t; + + return null; + } +} |
