Package org.hibernate.hql.ast.spi

Examples of org.hibernate.hql.ast.spi.QueryResolverProcessor


  private final QueryResolverProcessor resolverProcessor;
  private final QueryRendererProcessor rendererProcessor;
  private final MongoDBQueryRendererDelegate rendererDelegate;

  public MongoDBProcessingChain(SessionFactoryImplementor sessionFactory, EntityNamesResolver entityNames, Map<String, Object> namedParameters) {
    this.resolverProcessor = new QueryResolverProcessor( new MongoDBQueryResolverDelegate() );

    MongoDBPropertyHelper propertyHelper = new MongoDBPropertyHelper( sessionFactory, entityNames );
    MongoDBQueryRendererDelegate rendererDelegate = new MongoDBQueryRendererDelegate(
        sessionFactory,
        entityNames,
View Full Code Here


   private final LuceneQueryRendererDelegate rendererDelegate;
   private final IspnLuceneQueryResolverDelegate queryResolverDelegate;

   public IspnLuceneProcessingChain(SearchFactoryIntegrator searchFactory, EntityNamesResolver entityNames, Map<String, Object> namedParameters) {
      queryResolverDelegate = new IspnLuceneQueryResolverDelegate();
      resolverProcessor = new QueryResolverProcessor(queryResolverDelegate);

      LucenePropertyHelper propertyHelper = new LucenePropertyHelper(searchFactory) {
         @Override
         public Object convertToPropertyType(String value, Class<?> entityType, String... propertyPath) {
            Descriptors.FieldDescriptor field = queryResolverDelegate.getTargetType().findFieldByName(propertyPath[propertyPath.length - 1]);
View Full Code Here

  private final QueryResolverProcessor resolverProcessor;
  private final QueryRendererProcessor rendererProcessor;
  private final MongoDBQueryRendererDelegate rendererDelegate;

  public MongoDBProcessingChain(SessionFactoryImplementor sessionFactory, EntityNamesResolver entityNames, Map<String, Object> namedParameters) {
    this.resolverProcessor = new QueryResolverProcessor( new MongoDBQueryResolverDelegate() );

    MongoDBPropertyHelper propertyHelper = new MongoDBPropertyHelper( sessionFactory );
    MongoDBQueryRendererDelegate rendererDelegate = new MongoDBQueryRendererDelegate(
        entityNames,
        propertyHelper,
View Full Code Here

   private final LuceneQueryRendererDelegate rendererDelegate;
   private final IspnLuceneQueryResolverDelegate queryResolverDelegate;

   public IspnLuceneProcessingChain(SerializationContext serializationContext, SearchFactoryIntegrator searchFactory, EntityNamesResolver entityNames, Map<String, Object> namedParameters) {
      queryResolverDelegate = new IspnLuceneQueryResolverDelegate(serializationContext);
      resolverProcessor = new QueryResolverProcessor(queryResolverDelegate);

      LucenePropertyHelper propertyHelper = new LucenePropertyHelper(searchFactory) {
         @Override
         public Object convertToPropertyType(String value, Class<?> entityType, String... propertyPath) {
            Descriptors.FieldDescriptor field = queryResolverDelegate.getTargetType().findFieldByName(propertyPath[propertyPath.length - 1]);
View Full Code Here

   public FilterParsingResult getResult() {
      return rendererDelegate.getResult();
   }

   public static <TypeMetadata> FilterProcessingChain<TypeMetadata> build(ObjectPropertyHelper<TypeMetadata> propertyHelper, Map<String, Object> namedParameters) {
      QueryResolverProcessor resolverProcessor = new QueryResolverProcessor(new FilterQueryResolverDelegate(propertyHelper));

      SingleEntityQueryBuilder<BooleanExpr> queryBuilder = SingleEntityQueryBuilder.getInstance(new FilterPredicateFactory(propertyHelper.getEntityNamesResolver()), propertyHelper);

      FilterRendererDelegate rendererDelegate = new FilterRendererDelegate(propertyHelper, queryBuilder, namedParameters);
View Full Code Here

  private final QueryResolverProcessor resolverProcessor;
  private final QueryRendererProcessor rendererProcessor;
  private final MongoDBQueryRendererDelegate rendererDelegate;

  public MongoDBProcessingChain(SessionFactoryImplementor sessionFactory, EntityNamesResolver entityNames, Map<String, Object> namedParameters) {
    this.resolverProcessor = new QueryResolverProcessor( new MongoDBQueryResolverDelegate() );

    MongoDBPropertyHelper propertyHelper = new MongoDBPropertyHelper( sessionFactory, entityNames );
    MongoDBQueryRendererDelegate rendererDelegate = new MongoDBQueryRendererDelegate(
        entityNames,
        propertyHelper,
View Full Code Here

     *
     * @param fieldBridgeProvider the field bridge provider to use for querying the targeted dynamic entity type
     * @return a Lucene processing chain for parsing queries targeted at dynamic entities
     */
    public LuceneProcessingChain buildProcessingChainForDynamicEntities(FieldBridgeProvider fieldBridgeProvider) {
      QueryResolverProcessor resolverProcessor = new QueryResolverProcessor( new UntypedLuceneQueryResolverDelegate( ) );

      LuceneQueryRendererDelegate rendererDelegate = getRendererDelegate(
          searchFactory,
          fieldBridgeProvider,
          entityNames,
View Full Code Here

     * @return a Lucene processing chain for parsing queries targeted at Java class-based entities
     */
    public LuceneProcessingChain buildProcessingChainForClassBasedEntities() {
      ClassBasedLucenePropertyHelper propertyHelper = new ClassBasedLucenePropertyHelper( searchFactory, entityNames );

      QueryResolverProcessor resolverProcessor = new QueryResolverProcessor(
          new ClassBasedLuceneQueryResolverDelegate( propertyHelper, entityNames )
          );

      LuceneQueryRendererDelegate rendererDelegate = getRendererDelegate( searchFactory, null, entityNames, namedParameters, propertyHelper );

View Full Code Here

   public FilterParsingResult getResult() {
      return rendererDelegate.getResult();
   }

   public static <TypeMetadata> FilterProcessingChain<TypeMetadata> build(EntityNamesResolver entityNamesResolver, ObjectPropertyHelper<TypeMetadata> propertyHelper, Map<String, Object> namedParameters) {
      QueryResolverProcessor resolverProcessor = new QueryResolverProcessor(new FilterQueryResolverDelegate(entityNamesResolver, propertyHelper));

      SingleEntityQueryBuilder<BooleanExpr> queryBuilder = SingleEntityQueryBuilder.getInstance(new FilterPredicateFactory(entityNamesResolver), propertyHelper);

      FilterRendererDelegate<TypeMetadata> rendererDelegate = new FilterRendererDelegate<TypeMetadata>(entityNamesResolver, propertyHelper, queryBuilder, namedParameters);
View Full Code Here

   public FilterParsingResult getResult() {
      return rendererDelegate.getResult();
   }

   public static <TypeMetadata> FilterProcessingChain<TypeMetadata> build(ObjectPropertyHelper<TypeMetadata> propertyHelper, Map<String, Object> namedParameters) {
      QueryResolverProcessor resolverProcessor = new QueryResolverProcessor(new FilterQueryResolverDelegate(propertyHelper));

      SingleEntityQueryBuilder<BooleanExpr> queryBuilder = SingleEntityQueryBuilder.getInstance(new FilterPredicateFactory(propertyHelper.getEntityNamesResolver()), propertyHelper);

      FilterRendererDelegate<TypeMetadata> rendererDelegate = new FilterRendererDelegate<TypeMetadata>(propertyHelper, queryBuilder, namedParameters);
View Full Code Here

TOP

Related Classes of org.hibernate.hql.ast.spi.QueryResolverProcessor

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.