Package org.hibernate.loader.plan2.exec.process.internal

Examples of org.hibernate.loader.plan2.exec.process.internal.EntityReferenceInitializerImpl


        return new SimpleEntityIdentifierDescriptionImpl();
      }
    }

    // if we get here, we know we have a composite identifier...
    final Join join = expandingEntityQuerySpace().makeCompositeIdentifierJoin();
    return identifierDefinition.isEncapsulated()
        ? buildEncapsulatedCompositeIdentifierDescription( join )
        : buildNonEncapsulatedCompositeIdentifierDescription( join );
  }
View Full Code Here


        if ( type.isEntityType() ) {
          final EntityPersister indexPersister = persister.getFactory().getEntityPersister(
              ( (EntityType) type ).getAssociatedEntityName()
          );

          final Join join = collectionQuerySpace.addIndexEntityJoin(
              indexPersister,
              loadPlanBuildingContext
          );
          return new CollectionFetchableIndexEntityGraph( this, join );
        }
      }
      else if ( type.isComponentType() ) {
        final Join join = collectionQuerySpace.addIndexCompositeJoin(
            (CompositeType) type,
            loadPlanBuildingContext
        );
        return new CollectionFetchableIndexCompositeGraph( this, join );
      }
View Full Code Here

      if ( type.isEntityType() ) {
        final EntityPersister elementPersister = persister.getFactory().getEntityPersister(
            ( (EntityType) type ).getAssociatedEntityName()
        );

        final Join join = collectionQuerySpace.addElementEntityJoin( elementPersister, loadPlanBuildingContext );
        return new CollectionFetchableElementEntityGraph( this, join );
      }
    }
    else if ( type.isComponentType() ) {
      final Join join = collectionQuerySpace.addElementCompositeJoin(
          (CompositeType) type,
          loadPlanBuildingContext
      );
      return new CollectionFetchableElementCompositeGraph( this, join );
    }
View Full Code Here

              attributeDefinition.getName()
          )
      );
    }

    final Join join = querySpace.addEntityJoin(
        attributeDefinition,
        fetchedPersister,
        loadPlanBuildingContext.getQuerySpaces().generateImplicitUid(),
        attributeDefinition.isNullable()
    );
View Full Code Here

  @Override
  public CompositeFetch buildCompositeFetch(
      CompositionDefinition attributeDefinition,
      LoadPlanBuildingContext loadPlanBuildingContext) {
    final ExpandingQuerySpace leftHandSide = expandingQuerySpace();
    final Join join = leftHandSide.addCompositeJoin(
        attributeDefinition,
        loadPlanBuildingContext.getQuerySpaces().generateImplicitUid()
    );
    final CompositeFetch fetch = createCompositeFetch(
        attributeDefinition.getType(),
        (ExpandingCompositeQuerySpace) join.getRightHandSide()
    );
    addFetch( fetch );
    return fetch;
  }
View Full Code Here

              fetchedType.getRole(),
              attributeDefinition.getName()
          )
      );
    }
    final Join join = querySpace.addCollectionJoin(
        attributeDefinition,
        fetchedPersister,
        loadPlanBuildingContext.getQuerySpaces().generateImplicitUid()
    );
    final CollectionFetch fetch = new CollectionFetchImpl(
View Full Code Here

    }
    else if ( querySpaces.getRootQuerySpaces().size() > 1 ) {
      throw new IllegalStateException( "LoadPlan contained more than one root query-space" );
    }

    final QuerySpace querySpace = querySpaces.getRootQuerySpaces().get( 0 );
    if ( !returnType.isInstance( querySpace ) ) {
      throw new IllegalStateException(
          String.format(
              "Unexpected LoadPlan root query-space; expecting %s, but found %s",
              returnType.getName(),
              querySpace.getClass().getName()
          )
      );
    }

    return (T) querySpace;
View Full Code Here

    return querySpaceByUid.get( uid );
  }

  @Override
  public QuerySpace getQuerySpaceByUid(String uid) {
    final QuerySpace space = findQuerySpaceByUid( uid );
    if ( space == null ) {
      throw new QuerySpaceUidNotRegisteredException( uid );
    }
    return space;
  }
View Full Code Here

    log.debugf(
        "Adding QuerySpace : uid = %s -> %s]",
        querySpace.getUid(),
        querySpace
    );
    final QuerySpace previous = querySpaceByUid.put( querySpace.getUid(), querySpace );
    if ( previous != null ) {
      throw new IllegalStateException( "Encountered duplicate QuerySpace uid : " + querySpace.getUid() );
    }
  }
View Full Code Here

  @Override
  public QuerySpace getQuerySpaceByUid(String uid) {
    final QuerySpace space = findQuerySpaceByUid( uid );
    if ( space == null ) {
      throw new QuerySpaceUidNotRegisteredException( uid );
    }
    return space;
  }
View Full Code Here

TOP

Related Classes of org.hibernate.loader.plan2.exec.process.internal.EntityReferenceInitializerImpl

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.