Beispiel #1
0
 private void lookForLibraries() {
   List<NodeLibrary> libraries = new ArrayList<NodeLibrary>();
   libraries.add(systemLibrary("math"));
   libraries.add(systemLibrary("string"));
   libraries.add(systemLibrary("color"));
   libraries.add(systemLibrary("list"));
   libraries.add(systemLibrary("data"));
   libraries.add(systemLibrary("corevector"));
   if (Application.ENABLE_DEVICE_SUPPORT) {
     libraries.add(systemLibrary("device"));
   }
   if (Application.ENABLE_NETWORK_SUPPORT) {
     libraries.add(systemLibrary("network"));
   }
   systemRepository = NodeRepository.of(libraries.toArray(new NodeLibrary[] {}));
 }
Beispiel #2
0
 private NodeLibrary systemLibrary(String name) {
   String fileName = String.format("libraries/%s/%s.ndbx", name, name);
   return NodeLibrary.load(new File(fileName), NodeRepository.of());
 }