Package org.hibernate.annotations.common

Examples of org.hibernate.annotations.common.AssertionFailure


        }
        field.set( null, attribute );
      }
      catch ( IllegalAccessException e ) {
        // todo : exception type?
        throw new AssertionFailure(
            "Unable to inject static metamodel attribute : " + metamodelClass.getName() + '#' + name,
            e
        );
      }
      catch ( IllegalArgumentException e ) {
View Full Code Here


  public void popEntityWorkedOn(PersistentClass persistentClass) {
    final PersistentClass stackTop = stackOfPersistentClassesBeingProcessed.remove(
        stackOfPersistentClassesBeingProcessed.size() - 1
    );
    if (stackTop != persistentClass) {
      throw new AssertionFailure( "Inconsistent popping: "
        + persistentClass.getEntityName() + " instead of " + stackTop.getEntityName() );
    }
  }
View Full Code Here

  }

  public PersistentClass getPersistentClassHostingProperties(MappedSuperclassTypeImpl<?> mappedSuperclassType) {
    final PersistentClass persistentClass = mappedSuperClassTypeToPersistentClass.get( mappedSuperclassType );
    if (persistentClass == null) {
      throw new AssertionFailure( "Could not find PersistentClass for MappedSuperclassType: "
          + mappedSuperclassType.getJavaType() );
    }
    return persistentClass;
  }
View Full Code Here

        }
        embeddableType.lock();
        return embeddableType;
      }
      default: {
        throw new AssertionFailure( "Unknown type : " + typeContext.getValueClassification() );
      }
    }
  }
View Full Code Here

      return context.getSessionFactory()
        .getEntityPersister( persistentClass.getClassName() )
        .getEntityMetamodel();
    }
    else {
      throw new AssertionFailure( "Cannot get the metamodel for PersistenceType: " + persistenceType );
    }
  }
View Full Code Here

      else if ( type instanceof ParameterizedType ) {
        final java.lang.reflect.Type rawType = ( (ParameterizedType) type ).getRawType();
        return getClassFromGenericArgument( rawType );
      }
      else {
        throw new AssertionFailure(
            "Fail to process type argument in a generic declaration. Member : " + getMemberDescription()
                + " Type: " + type.getClass()
        );
      }
    }
View Full Code Here

          case PLURAL_ATTRIBUTE : {
            declaredPluralAttributes.put(attribute.getName(), (PluralAttribute<X,?,?>) attribute );
            break;
          }
          default : {
            throw new AssertionFailure( "unknown bindable type: " + bindableType );
          }
        }
      }
    };
  }
View Full Code Here

        finally {
                    LOG.trace("Completed mapped superclass [" + safeMapping.getMappedClass().getName() + "]");
        }
      }
      else {
        throw new AssertionFailure( "Unexpected mapping type: " + mapping.getClass() );
      }
    }

    for ( EmbeddableTypeImpl embeddable : embeddables.values() ) {
      populateStaticMetamodel( embeddable );
View Full Code Here

        }
        field.set( null, attribute );
      }
      catch ( IllegalAccessException e ) {
        // todo : exception type?
        throw new AssertionFailure(
            "Unable to inject static metamodel attribute : " + metamodelClass.getName() + '#' + name,
            e
        );
      }
      catch ( IllegalArgumentException e ) {
View Full Code Here

  public void popEntityWorkedOn(PersistentClass persistentClass) {
    final PersistentClass stackTop = stackOfPersistentClassesBeingProcessed.remove(
        stackOfPersistentClassesBeingProcessed.size() - 1
    );
    if (stackTop != persistentClass) {
      throw new AssertionFailure( "Inconsistent popping: "
        + persistentClass.getEntityName() + " instead of " + stackTop.getEntityName() );
    }
  }
View Full Code Here

TOP

Related Classes of org.hibernate.annotations.common.AssertionFailure

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.