Examples of using()


Examples of org.hibernate.NaturalIdLoadAccess.using()

      if ( naturalIdValue == null ) {
        // A NaturalId property is missing from the critera query, can't use NaturalIdLoadAccess
        return null;
      }

      naturalIdLoader.using( naturalIdProperty, naturalIdValue );
    }

    // Critera query contains a valid naturalId, use the new API
    LOG.warn( "Session.byNaturalId(" + entityName
        + ") should be used for naturalId queries instead of Restrictions.naturalId() from a Criteria" );
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

         public Citizen call() throws Exception {
            Session s = openSession();
            Transaction tx = s.beginTransaction();
            State france = BasicTransactionalTestCase.this.getState(s, "Ile de France");
            NaturalIdLoadAccess naturalIdLoader = s.byNaturalId(Citizen.class);
            naturalIdLoader.using("ssn", "1234").using("state", france);

            //Not clearing naturalId caches, should be warm from entity loading
            stats.clear();

            // first query
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

         public Void call() throws Exception {
            Session s = openSession();
            Transaction tx = s.beginTransaction();
            State france = BasicTransactionalTestCase.this.getState(s, "Ile de France");
            NaturalIdLoadAccess naturalIdLoader = s.byNaturalId(Citizen.class);
            naturalIdLoader.using( "ssn", "1234" ).using( "state", france );

            //Not clearing naturalId caches, should be warm from entity loading
            stats.setStatisticsEnabled( true );
            stats.clear();
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

      if ( naturalIdValue == null ) {
        // A NaturalId property is missing from the critera query, can't use NaturalIdLoadAccess
        return null;
      }

      naturalIdLoader.using( naturalIdProperty, naturalIdValue );
    }

    // Critera query contains a valid naturalId, use the new API
    LOG.warn( "Session.byNaturalId(" + entityName
        + ") should be used for naturalId queries instead of Restrictions.naturalId() from a Criteria" );
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

      if ( naturalIdValue == null ) {
        // A NaturalId property is missing from the critera query, can't use NaturalIdLoadAccess
        return null;
      }

      naturalIdLoader.using( naturalIdProperty, naturalIdValue );
    }

    // Critera query contains a valid naturalId, use the new API
    LOG.warn( "Session.byNaturalId(" + entityName
        + ") should be used for naturalId queries instead of Restrictions.naturalId() from a Criteria" );
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

      if ( naturalIdValue == null ) {
        // A NaturalId property is missing from the critera query, can't use NaturalIdLoadAccess
        return null;
      }

      naturalIdLoader.using( naturalIdProperty, naturalIdValue );
    }

    // Critera query contains a valid naturalId, use the new API
    LOG.warn( "Session.byNaturalId(" + entityName
        + ") should be used for naturalId queries instead of Restrictions.naturalId() from a Criteria" );
View Full Code Here

Examples of org.hibernate.NaturalIdLoadAccess.using()

      if ( naturalIdValue == null ) {
        // A NaturalId property is missing from the critera query, can't use NaturalIdLoadAccess
        return null;
      }

      naturalIdLoader.using( naturalIdProperty, naturalIdValue );
    }

    // Critera query contains a valid naturalId, use the new API
    LOG.warn( "Session.byNaturalId(" + entityName
        + ") should be used for naturalId queries instead of Restrictions.naturalId() from a Criteria" );
View Full Code Here

Examples of org.jboss.arquillian.persistence.core.metadata.MetadataExtractor.using()

         final MetadataExtractor metadataExtractor = metadataExtractorInstance.get();
         final ExpectedDataSetProvider dataSetProvider = new ExpectedDataSetProvider(metadataExtractor, configurationInstance.get());
         final Method testMethod = afterPersistenceTest.getTestMethod();
         final ShouldMatchDataSet dataSetsToVerify = metadataExtractor.shouldMatchDataSet()
                                                                      .fetchFrom(testMethod);
         final CustomColumnFilter customColumnFilter = metadataExtractor.using(CustomColumnFilter.class).fetchFrom(testMethod);
         final CompareDBUnitData compareDBUnitDataEvent = new CompareDBUnitData(dataSetProvider.getDescriptorsDefinedFor(testMethod), dataSetsToVerify.orderBy(), dataSetsToVerify.excludeColumns());
         if (customColumnFilter != null)
         {
               compareDBUnitDataEvent.add(customColumnFilter.value());
         }
View Full Code Here

Examples of org.jboss.shrinkwrap.resolver.api.maven.MavenStrategyStage.using()

    @Test
    public void resolveProvidedDependency() throws Exception {
        final String coordinates = "org.jboss.xnio:xnio-api:jar:3.1.0.Beta7";

        final MavenStrategyStage mss = Maven.configureResolver().fromFile(SETTINGS_XML).resolve(coordinates);
        final MavenFormatStage mfs = mss.using(STRATEGY);
        final MavenResolvedArtifact info = mfs.asSingleResolvedArtifact();
        Assert.assertNotNull(info);
        final MavenArtifactInfo[] dependencies = info.getDependencies();
        Assert.assertNotNull(dependencies);
        // http://search.maven.org/remotecontent?filepath=org/jboss/xnio/xnio-api/3.1.0.Beta7/xnio-api-3.1.0.Beta7.pom
View Full Code Here

Examples of org.modeshape.jcr.query.QueryEngineBuilder.using()

                        // There are no indexes ...
                        builder = ScanningQueryEngine.builder();
                        logger.debug("Queries with no indexes are enabled for the '{0}' repository. Executing queries will always scan the repository contents.",
                                     repoConfig.getName());
                    }
                    queryEngine = builder.using(repoConfig, indexManager, runningState.context()).build();
                }
            } finally {
                engineInitLock.unlock();
            }
        }
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.