Package org.datanucleus.plugin

Examples of org.datanucleus.plugin.NonManagedPluginRegistry$ExtensionSorter


            public void clearFilters(){}
            public void addFilter(Filter arg0){}
       
        });
        ClassLoaderResolver clr = new JDOClassLoaderResolver();
        NonManagedPluginRegistry mgr = new NonManagedPluginRegistry(clr, "EXCEPTION");
        assertEquals(0,mgr.getExtensionPoints().length);
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST3.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST4.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST5.MF",null));
        mgr.resolveConstraints();
        try
        {
            assertEquals(2,messages.size());
            assertTrue(messages.contains("Bundle \"org.datanucleus.plugin.test5\" requires \"org.datanucleus.plugin.test6\" but it cannot be resolved."));
            assertTrue(messages.contains("Bundle \"org.datanucleus.plugin.test5\" has an optional dependency to \"org.datanucleus.plugin.test7\" but it cannot be resolved"));
View Full Code Here


            public void clearFilters(){}
            public void addFilter(Filter arg0){}
       
        });
        ClassLoaderResolver clr = new JDOClassLoaderResolver();
        NonManagedPluginRegistry mgr = new NonManagedPluginRegistry(clr, "EXCEPTION");
        assertEquals(0,mgr.getExtensionPoints().length);
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST10.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST11.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST12.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST13.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST14.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST15.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST16.MF",null));
        mgr.registerBundle(clr.getResource("/org/datanucleus/samples/plugin/MANIFEST17.MF",null));
        mgr.resolveConstraints();
        try
        {
            assertEquals(3,messages.size());
            assertTrue(messages.contains("Bundle \"org.datanucleus.plugin.test12\" requires \"org.datanucleus.plugin.test11\" version \"(1.2.0.b2\" but the resolved bundle has version \"1.2.0.b2\" which is outside the expected range."));
            assertTrue(messages.contains("Bundle \"org.datanucleus.plugin.test13\" requires \"org.datanucleus.plugin.test11\" version \"(1.2.0.c1\" but the resolved bundle has version \"1.2.0.b2\" which is outside the expected range."));
View Full Code Here

TOP

Related Classes of org.datanucleus.plugin.NonManagedPluginRegistry$ExtensionSorter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.