Package org.hibernate.dialect.lock

Examples of org.hibernate.dialect.lock.OptimisticLockingStrategy


//    else if ( lockMode==LockMode.PESSIMISTIC_READ ) {
      //TODO find a more efficient pessimistic read
//      return new EhcachePessimisticWriteLockingStrategy( lockable, lockMode );
//    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    throw new UnsupportedOperationException( "LockMode " + lockMode + " is not supported by the Ehcache GridDialect" );
View Full Code Here


    else if ( lockMode == LockMode.PESSIMISTIC_READ ) {
      // TODO find a more efficient pessimistic read
      return new InfinispanPessimisticWriteLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    throw new UnsupportedOperationException( "LockMode " + lockMode
View Full Code Here

    }
    else if ( lockMode == LockMode.PESSIMISTIC_READ ) {
      return new MapPessimisticReadLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    return new MapPessimisticWriteLockingStrategy( lockable, lockMode );
View Full Code Here

            case PESSIMISTIC_WRITE:
                return new PessimisticWriteSelectLockingStrategy( lockable, lockMode );
            case PESSIMISTIC_READ:
                return new PessimisticReadSelectLockingStrategy( lockable, lockMode );
            case OPTIMISTIC:
                return new OptimisticLockingStrategy( lockable, lockMode );
            case OPTIMISTIC_FORCE_INCREMENT:
                return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
            default:
                return new SelectLockingStrategy( lockable, lockMode );
        }
View Full Code Here

    }
    else if ( lockMode == LockMode.PESSIMISTIC_READ ) {
      return new MapPessimisticReadLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    return new MapPessimisticWriteLockingStrategy( lockable, lockMode );
View Full Code Here

    }
    else if ( lockMode==LockMode.PESSIMISTIC_READ) {
      return new PessimisticReadUpdateLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode==LockMode.OPTIMISTIC) {
      return new OptimisticLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode==LockMode.OPTIMISTIC_FORCE_INCREMENT) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode.greaterThan( LockMode.READ ) ) {
View Full Code Here

            case PESSIMISTIC_WRITE:
                return new PessimisticWriteSelectLockingStrategy( lockable, lockMode );
            case PESSIMISTIC_READ:
                return new PessimisticReadSelectLockingStrategy( lockable, lockMode );
            case OPTIMISTIC:
                return new OptimisticLockingStrategy( lockable, lockMode );
            case OPTIMISTIC_FORCE_INCREMENT:
                return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
            default:
                return new SelectLockingStrategy( lockable, lockMode );
        }
View Full Code Here

    }
    else if ( lockMode==LockMode.PESSIMISTIC_READ) {
      return new PessimisticReadUpdateLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode==LockMode.OPTIMISTIC) {
      return new OptimisticLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode==LockMode.OPTIMISTIC_FORCE_INCREMENT) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode);
    }
    else if ( lockMode.greaterThan( LockMode.READ ) ) {
View Full Code Here

    }
    else if ( lockMode == LockMode.PESSIMISTIC_READ ) {
      return new PessimisticReadUpdateLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode.greaterThan( LockMode.READ ) ) {
View Full Code Here

    }
    else if ( lockMode == LockMode.PESSIMISTIC_READ ) {
      return new PessimisticReadUpdateLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC ) {
      return new OptimisticLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode == LockMode.OPTIMISTIC_FORCE_INCREMENT ) {
      return new OptimisticForceIncrementLockingStrategy( lockable, lockMode );
    }
    else if ( lockMode.greaterThan( LockMode.READ ) ) {
View Full Code Here

TOP

Related Classes of org.hibernate.dialect.lock.OptimisticLockingStrategy

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.