1 package net.mograsim.logic.model.am2900;
3 import java.util.concurrent.atomic.AtomicBoolean;
5 import org.osgi.framework.BundleActivator;
6 import org.osgi.framework.BundleContext;
8 import net.mograsim.logic.model.serializing.ClassLoaderBasedResourceLoader;
9 import net.mograsim.logic.model.serializing.IndirectGUIComponentCreator;
11 public class Am2900Loader implements BundleActivator
13 private static AtomicBoolean activated = new AtomicBoolean(false);
16 public void start(BundleContext context) throws Exception
22 public void stop(BundleContext context) throws Exception
27 public static void setup()
29 if (activated.getAndSet(true))
31 ClassLoaderBasedResourceLoader resourceLoader = ClassLoaderBasedResourceLoader.create(Am2900Loader.class.getClassLoader());
32 IndirectGUIComponentCreator.registerResourceLoader(resourceLoader, "Am2900Loader");
33 IndirectGUIComponentCreator.loadStandardComponentIDs(Am2900Loader.class.getResourceAsStream("standardComponentIDMapping.json"));
34 // System.out.println("SETUP DONE"); // TODO: Debug