Examples of PersistenceConfiguration


Examples of org.datanucleus.PersistenceConfiguration

   * Method to create the IdentifierFactory to be used by this store.
   * Relies on the datastore adapter existing before creation
   * @param omfContext ObjectManagerFactory context
   */
  protected void initialiseIdentifierFactory(OMFContext omfContext) {
    PersistenceConfiguration conf = omfContext.getPersistenceConfiguration();
    String idFactoryName = conf.getStringProperty("datanucleus.identifierFactory");
    String idFactoryClassName = omfContext.getPluginManager()
        .getAttributeValueForExtension("org.datanucleus.store_identifierfactory",
            "name", idFactoryName, "class-name");
    if (idFactoryClassName == null) {
      throw new FatalNucleusUserException(idFactoryName);
View Full Code Here

Examples of org.infinispan.configuration.cache.PersistenceConfiguration

      InputStream is = new ByteArrayInputStream(config.getBytes());
      withCacheManager(new CacheManagerCallable(TestCacheManagerFactory.fromStream(is)) {
         @Override
         public void call() {
            PersistenceConfiguration cfg = cm.getDefaultCacheConfiguration().persistence();
            StoreConfiguration config = cfg.stores().get(0);
            assertTrue(config instanceof DummyInMemoryStoreConfiguration);
            DummyInMemoryStoreConfiguration dummyInMemoryStoreConfiguration = (DummyInMemoryStoreConfiguration)config;
            assertEquals("myStore", dummyInMemoryStoreConfiguration.storeName());
         }
      });
View Full Code Here

Examples of org.jboss.arquillian.persistence.configuration.PersistenceConfiguration

   InstanceProducer<PersistenceConfiguration> configurationProducer;

   @Override
   protected PersistenceConfiguration create()
   {
      return new PersistenceConfiguration();
   }
View Full Code Here

Examples of org.jboss.arquillian.persistence.core.configuration.PersistenceConfiguration

            final MetadataExtractor extractor = new MetadataExtractor(event.getTestClass());
            final boolean isActive = new PersistenceExtensionEnabler(extractor).shouldPersistenceExtensionBeActivated();
            active.set(isActive);

            if (isActive) {
                final PersistenceConfiguration persistenceConfiguration = configurationInstance.get();
                persistenceExtensionFeatureResolverProvider.set(new PersistenceExtensionFeatureResolver(event.getTestMethod(), extractor, persistenceConfiguration));
                persistenceExtensionScriptingFeatureResolverProvider.set(new PersistenceExtensionScriptingFeatureResolver(event.getTestMethod(), extractor, scriptingConfigurationInstance.get()));

                beforePersistenceTestEvent.fire(new BeforePersistenceTest(event));
            }
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

    /**
     * Test of the valid locations for a specified package.
     */
    public void testLocationsForPackage()
    {
        JDOMetaDataManager mgr = new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){}));

        // Try typical JDO package name
        String packageName = "org.jpox.samples";
        List locations = mgr.getValidMetaDataLocationsForPackage("jdo", null, packageName);
        assertTrue("Locations returned from MetaData Manager was null!", locations != null);
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

    /**
     * Test of the valid locations for a specified class.
     */
    public void testLocationsForClass()
    {
        JDOMetaDataManager mgr = new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){}));

        // Try typical JDO class name
        String className = "org.jpox.samples.store.Product";
        List locations = mgr.getValidMetaDataLocationsForClass("jdo", null, className);
        assertTrue("Locations returned from MetaData Manager was null!", locations != null);
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

{


    public void testParseMetaDataURLnullURL()
    {
        MetaDataParser parser = new MetaDataParser(new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){})),true);
        try
        {
            parser.parseMetaDataURL(null, "jdo");
            fail("expected JPOXException");
        }
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

        }
    }

    public void testParseMetaDataURLnullhandler()
    {
        MetaDataParser parser = new MetaDataParser(new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){})),true);
        try
        {
            parser.parseMetaDataURL(getClass().getResource("/org/jpox/metadata/xml/package2.jdo"), null);
            fail("expected JPOXException");
        }
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

public class PersistenceFileMetaDataHandlerTest extends TestCase
{
    public void testParseDefaultNamespace()
    {
        MetaDataParser parser = new MetaDataParser(new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){})),true);
        MetaData md = parser.parseMetaDataURL(getClass().getResource("/org/jpox/metadata/xml/persistence1.xml"), "persistence");
        assertNotNull(md);
    }
View Full Code Here

Examples of org.jpox.PersistenceConfiguration

        assertNotNull(md);
    }

    public void testParseNamespace()
    {
        MetaDataParser parser = new MetaDataParser(new JDOMetaDataManager(new OMFContext(new PersistenceConfiguration(){})),true);
        MetaData md = parser.parseMetaDataURL(getClass().getResource("/org/jpox/metadata/xml/persistence2.xml"), "persistence");
        assertNotNull(md);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.