Package org.hibernate.ogm.util.configurationreader.impl

Examples of org.hibernate.ogm.util.configurationreader.impl.ConfigurationPropertyReader


* @author Davide D'Alto <davide@hibernate.org>
*/
public class Neo4jGraphDatabaseServiceFactoryProvider {

  public GraphDatabaseServiceFactory load(Map<?, ?> properties, ClassLoaderService classLoaderService) {
    GraphDatabaseServiceFactory factory = new ConfigurationPropertyReader(properties, classLoaderService )
      .property( InternalProperties.NEO4J_GRAPHDB_FACTORYCLASS, GraphDatabaseServiceFactory.class )
      .instantiate()
      .withDefaultImplementation( EmbeddedGraphDatabaseFactory.class )
      .getValue();

View Full Code Here


  private Map<?, ?> configuration;

  @Override
  public void initialize(Map<?, ?> properties) {
    ConfigurationPropertyReader configurationPropertyReader = new ConfigurationPropertyReader( properties );

    this.dbLocation = configurationPropertyReader.property( Neo4jProperties.DATABASE_PATH, String.class )
        .required()
        .getValue();

    this.configurationLocation = configurationPropertyReader
        .property( Neo4jProperties.CONFIGURATION_RESOURCE_NAME, URL.class )
        .getValue();

    configuration = properties;
  }
View Full Code Here

   *
   * @param configurationMap
   *            The values to use as configuration
   */
  public void initConfiguration(Map configurationMap) {
    ConfigurationPropertyReader propertyReader = new ConfigurationPropertyReader( configurationMap );

    this.configUrl = propertyReader
        .property( InfinispanProperties.CONFIGURATION_RESOURCE_NAME, URL.class )
        .withDefault( InfinispanConfiguration.class.getClassLoader().getResource( INFINISPAN_DEFAULT_CONFIG ) )
        .getValue();

    this.jndi = propertyReader
        .property( InfinispanProperties.CACHE_MANAGER_JNDI_NAME, String.class )
        .getValue();

    log.tracef( "Initializing Infinispan from configuration file at %1$s", configUrl );
  }
View Full Code Here

  public CouchDBDatastoreProvider() {
  }

  @Override
  public void configure(Map configurationValues) {
    configuration = new CouchDBConfiguration( new ConfigurationPropertyReader( configurationValues ) );
  }
View Full Code Here

TOP

Related Classes of org.hibernate.ogm.util.configurationreader.impl.ConfigurationPropertyReader

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.