Package org.hibernate.annotations

Examples of org.hibernate.annotations.Persister


    final boolean includeInOptimisticLockChecks = ( lockAnn != null )
        ? ! lockAnn.excluded()
        : ! isMappedBy;
    collection.setOptimisticLocked( includeInOptimisticLockChecks );

    Persister persisterAnn = property.getAnnotation( Persister.class );
    if ( persisterAnn != null ) {
      collection.setCollectionPersisterClass( persisterAnn.impl() );
    }

    applySortingAndOrdering( collection );

    //set cache
View Full Code Here


    final boolean includeInOptimisticLockChecks = ( lockAnn != null )
        ? ! lockAnn.excluded()
        : ! isMappedBy;
    collection.setOptimisticLocked( includeInOptimisticLockChecks );

    Persister persisterAnn = property.getAnnotation( Persister.class );
    if ( persisterAnn != null ) {
      collection.setCollectionPersisterClass( persisterAnn.impl() );
    }

    // set ordering
    if ( orderBy != null ) collection.setOrderBy( orderBy );
    if ( isSorted ) {
View Full Code Here

    final boolean includeInOptimisticLockChecks = ( lockAnn != null )
        ? ! lockAnn.excluded()
        : ! isMappedBy;
    collection.setOptimisticLocked( includeInOptimisticLockChecks );

    Persister persisterAnn = property.getAnnotation( Persister.class );
    if ( persisterAnn != null ) {
      collection.setCollectionPersisterClass( persisterAnn.impl() );
    }

    applySortingAndOrdering( collection );

    //set cache
View Full Code Here

    persistentClass.setOptimisticLockMode( getVersioning( optimisticLockType ) );
    persistentClass.setSelectBeforeUpdate( selectBeforeUpdate );

    //set persister if needed
    //@Persister has precedence over @Entity.persister
    Persister persisterAnn = annotatedClass.getAnnotation( Persister.class );
    Class persister = null;
    if ( persisterAnn != null ) {
      persister = persisterAnn.impl();
    }
    else {
      org.hibernate.annotations.Entity entityAnn = annotatedClass.getAnnotation( org.hibernate.annotations.Entity.class );
      if ( entityAnn != null && !BinderHelper.isDefault( entityAnn.persister() ) ) {
        try {
View Full Code Here

    }

    collection.setMutable( !property.isAnnotationPresent( Immutable.class ) );
    OptimisticLock lockAnn = property.getAnnotation( OptimisticLock.class );
    if ( lockAnn != null ) collection.setOptimisticLocked( !lockAnn.excluded() );
    Persister persisterAnn = property.getAnnotation( Persister.class );
    if ( persisterAnn != null ) collection.setCollectionPersisterClass( persisterAnn.impl() );

    // set ordering
    if ( orderBy != null ) collection.setOrderBy( orderBy );
    if ( isSorted ) {
      collection.setSorted( true );
View Full Code Here

    final boolean includeInOptimisticLockChecks = ( lockAnn != null )
        ? ! lockAnn.excluded()
        : ! isMappedBy;
    collection.setOptimisticLocked( includeInOptimisticLockChecks );

    Persister persisterAnn = property.getAnnotation( Persister.class );
    if ( persisterAnn != null ) {
      collection.setCollectionPersisterClass( persisterAnn.impl() );
    }

    applySortingAndOrdering( collection );

    //set cache
View Full Code Here

    persistentClass.setOptimisticLockMode( getVersioning( optimisticLockType ) );
    persistentClass.setSelectBeforeUpdate( selectBeforeUpdate );

    //set persister if needed
    //@Persister has precedence over @Entity.persister
    Persister persisterAnn = annotatedClass.getAnnotation( Persister.class );
    Class persister = null;
    if ( persisterAnn != null ) {
      persister = persisterAnn.impl();
    }
    else {
      org.hibernate.annotations.Entity entityAnn = annotatedClass.getAnnotation( org.hibernate.annotations.Entity.class );
      if ( entityAnn != null && !BinderHelper.isDefault( entityAnn.persister() ) ) {
        try {
View Full Code Here

TOP

Related Classes of org.hibernate.annotations.Persister

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.