Examples of adaptorValueType()


Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

        defaultLog.debug("Adding: " + name + "-" + defaultValue);
        NSArray attrs = rel.destinationAttributes();
        if(!rel.isFlattened() && attrs !=  null && attrs.count() == 1) {
            EOAttribute relAttr = (EOAttribute)attrs.objectAtIndex(0);
            if(defaultValue != null) {
                RelationshipDefault d = new RelationshipDefault(name, defaultValue, relAttr.adaptorValueType(), rel.destinationEntity().name());
                _initialDefaultValues.setObjectForKey(d, name);
            }
        }
    }
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

            if(rawValue instanceof NSArray) {
                int index = 0;
                for(Enumeration e = ((NSArray)rawValue).objectEnumerator(); e.hasMoreElements();) {
                    EOAttribute attribute = pks.objectAtIndex(index++);
                    Object value = e.nextElement();
                    if(attribute.adaptorValueType() == EOAttribute.AdaptorDateType && !(value instanceof NSTimestamp)) {
                        value = new NSTimestampFormatter("%Y-%m-%d %H:%M:%S %Z").parseObject((String)value);
                    }
                    value = attribute.validateValue(value);
                    pk.setObjectForKey(value, attribute.name());
                    if(pks.count() == 1) {
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

            NSArray<EOAttribute> priKeyAttributes = entity.primaryKeyAttributes();
            if (priKeyAttributes.count() == 1) {
                EOAttribute priKeyAttribute = priKeyAttributes.objectAtIndex(0);
               
                // Q: Don't create a sequence for non number primary keys
                if (priKeyAttribute.adaptorValueType() != EOAttribute.AdaptorNumberType) {
                  continue;
                }

                String sequenceName = PostgresqlPlugIn._sequenceNameForEntity(entity);
                if (!sequenceNames.containsObject(sequenceName)) {
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

        NSMutableDictionary result = new NSMutableDictionary( attrCount );
        for( int i = 0; i < attrCount; i++ ) {
            String currentAttributeName = (String)pkAttributeNames.objectAtIndex( i );
            EOAttribute currentAttribute = entity.attributeNamed( currentAttributeName );
            Object currentValue = values.objectAtIndex( i );
            switch ( currentAttribute.adaptorValueType() ) {
                case 3:
                    NSTimestampFormatter tsf = new NSTimestampFormatter();
                    try {
                        currentValue = tsf.parseObject( (String) currentValue );   
                    } catch( java.text.ParseException ex ) {
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

      boolean isLike =
          qualifierSelector.equals( EOQualifier.QualifierOperatorLike ) || qualifierSelector.equals( EOQualifier.QualifierOperatorCaseInsensitiveLike );
      boolean isStringComparison =
          isLike
          || EOAttribute.AdaptorCharactersType == leftAttribute.adaptorValueType()
          || EOAttribute.AdaptorCharactersType == rightAttribute.adaptorValueType();
     
      String binaryOperator = isStringComparison ? "BINARY " : "";
     
      return _NSStringUtilities.concat( binaryOperator, leftKeyString, " ", operatorString, " ", rightKeyString );
    }
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

   
    keyString = formatSQLString( keyString, attribute.readFormat() );
    NSSelector qualifierSelector = qualifier.selector();
    boolean isLike =
        qualifierSelector.equals( EOQualifier.QualifierOperatorLike ) || qualifierSelector.equals( EOQualifier.QualifierOperatorCaseInsensitiveLike );
    boolean isStringComparison = isLike || EOAttribute.AdaptorCharactersType == attribute.adaptorValueType();
   
    Object value;
    if ( isLike )
    {
      value = sqlPatternFromShellPattern( ( String )qualifierValue );
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

        if (priKeyAttributes.count() == 1 && externalName != null && externalName.length() > 0) {
          EOAttribute priKeyAttribute = priKeyAttributes.objectAtIndex(0);
         
          // pk counter not needed for non number primary key
          if (priKeyAttribute.adaptorValueType() != EOAttribute.AdaptorNumberType) {
            continue;
          }

          String unique = null;
          if (eoentity.model() != null) {
View Full Code Here

Examples of com.webobjects.eoaccess.EOAttribute.adaptorValueType()

            priKeyAttributes = entity.primaryKeyAttributes();
            if (priKeyAttributes.count() == 1) {
                priKeyAttribute = (EOAttribute) priKeyAttributes.objectAtIndex(0);
               
                // Q: Don't create a sequence for non number primary keys
                if (priKeyAttribute.adaptorValueType() != EOAttribute.AdaptorNumberType) {
                  continue;
                }
                String sql;

                sequenceName = DB2PlugIn._sequenceNameForEntity(entity);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.