Package com.adaptrex.core.ext

Examples of com.adaptrex.core.ext.FieldDefinition


 
  public JPAAssociationType(SingularAttribute<?,?> association, SecureEntity secureEntity) {
    super(association.getName(), association.getJavaType(), secureEntity);
    String associationName = association.getName();
    this.idFieldDefinition =
        new FieldDefinition(
            associationName + StringUtils.capitalize(AdaptrexEntityType.ENTITY_ID_NAME),
            ExtTypeFormatter.AUTO);
   
    String capName = StringUtilities.capitalize(getName());
   
View Full Code Here


          StringUtilities.uncapitalize(relEntityName)
        );
      this.name = relName;
      this.itemType = dataMap.getObjEntity(relEntityName).getJavaClass();
      this.idsFieldDefinition =
          new FieldDefinition(
              StringUtilities.uncapitalize(relEntityName) +
                AdaptrexEntityType.COLLECTION_IDS_NAME,
              ExtTypeFormatter.AUTO
            );
     
      /*
       * Get the methods to grab the join table and target table
       */
      try {
        joinGetter = declaringClass.getMethod(
            "get" + StringUtilities.pluralize(joinTable.getSimpleName()));
        targetGetter = joinTable.getMethod("get" + this.itemType.getSimpleName());
       
        primarySetter = joinTable.getMethod("set" + declaringClass.getSimpleName(), declaringClass);
        targetSetter = joinTable.getMethod("set" + this.itemType.getSimpleName(), this.itemType);
      } catch (Exception e) {}
     
     
     
     
    }
   
   
    /*
     * Flattened association
     */
    else {
      String relName = StringUtilities.singularize(relationship.getName());
      this.idsFieldDefinition =
          new FieldDefinition(
              relName + AdaptrexEntityType.COLLECTION_IDS_NAME,
              ExtTypeFormatter.AUTO
            );
     
      String capName = StringUtilities.capitalize(getName());
View Full Code Here

  private Method setter;
 
  public CayenneAssociationType(ObjEntity objEntity, ObjRelationship relationship, Class<?> associationType, SecureEntity secureEntity) {
    super(relationship.getName(), associationType, secureEntity);
    this.idFieldDefinition =
        new FieldDefinition(
            relationship.getName() + AdaptrexEntityType.ENTITY_ID_NAME,
            ExtTypeFormatter.STRING
          );
   
    String capName = StringUtilities.capitalize(getName());
View Full Code Here

  public JPACollectionType(PluralAttribute<?,?,?> collection, SecureEntity secureEntity) {
    super(collection.getName(), collection.getJavaType(), collection.getElementType().getJavaType(), secureEntity);
   
    String relName = StringUtilities.singularize(collection.getName());
    this.idsFieldDefinition =
        new FieldDefinition(
            relName + AdaptrexEntityType.COLLECTION_IDS_NAME,
            ExtTypeFormatter.AUTO
          );
   
    String capName = StringUtilities.capitalize(getName());
View Full Code Here

 
  public JPAAssociationType(SingularAttribute<?,?> association, SecureEntity secureEntity) {
    super(association.getName(), association.getJavaType(), secureEntity);
    String associationName = association.getName();
    this.idFieldDefinition =
        new FieldDefinition(
            associationName + AdaptrexEntityType.ENTITY_ID_NAME,
            ExtTypeFormatter.AUTO);
   
    String capName = StringUtilities.capitalize(getName());
   
View Full Code Here

TOP

Related Classes of com.adaptrex.core.ext.FieldDefinition

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.