Examples of userInfo()


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

            }
        }
        if (entity!=null && lastKey!=null) {
            EOAttribute a=entity.attributeNamed(lastKey);
            NSDictionary userInfo=null;
            if (a!=null) userInfo=a.userInfo();
            else {
                EORelationship r=entity.relationshipNamed(lastKey);
                if (r!=null) userInfo=r.userInfo();
            }
            result= (String)(userInfo!=null ? userInfo.valueForKey("unit") : null);
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

    public void readDefaultValues() {
        if(_initialDefaultValues == null) {
            _initialDefaultValues = new NSMutableDictionary();

            EOEntity entity = entity();
            NSDictionary entityInfo = (NSDictionary)entity.userInfo().objectForKey("ERXDefaultValues");

            for( Enumeration e = entity.attributes().objectEnumerator(); e.hasMoreElements();) {
                EOAttribute attr = (EOAttribute)e.nextElement();
                String defaultValue = null;
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

    public String indexKey(){
        final EOEntity destinationEntity = destinationEntity();
        String indexKey = null;

        if ( destinationEntity != null ) {
            final String isSortedJoinValue = (String)destinationEntity.userInfo().valueForKey("isSortedJoinEntity");

            if ( "true".equals(isSortedJoinValue) ) {
                synchronized (_context) {
                    _context.setEntity(destinationEntity);
                    indexKey = (String)_context.valueForKey("indexKey");
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

     * @author David Avendasora
     */
    public static <T extends ERXCopyable<T>> T modelCopy(NSMutableDictionary<EOGlobalID, ERXCopyable<?>> copiedObjects, T source) {
      EOEntity entity = Utility.entity(source);
      EOModel model = entity.model();
      NSDictionary<String, Object> entityUserInfo = entity.userInfo();
      String entityName = entity.name();
      String modelName = model.name();

      if (!entityUserInfo.containsKey(ERXCopyable.ERXCOPYABLE_KEY)) {
        String message = "In order to use modelCopy the \"" + ERXCopyable.ERXCOPYABLE_KEY + "\" key must be set in the UserInfo dictionary of the \"" + entityName + "\" Entity in the " + modelName + " EOModel.";
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

        EOModelGroup group = (EOModelGroup) n.object();
        for (Enumeration e = group.models().objectEnumerator(); e.hasMoreElements();) {
            EOModel model = (EOModel) e.nextElement();
            for (Enumeration e1 = model.entities().objectEnumerator(); e1.hasMoreElements();) {
                EOEntity entity = (EOEntity) e1.nextElement();
                if (entity.userInfo() != null && entity.userInfo().objectForKey(ERXAUDIT_KEYS) != null) {
                    configureEntity(entity);
                }
            }
        }
        log.info("Configuration : " + configuration);
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

        EOModelGroup group = (EOModelGroup) n.object();
        for (Enumeration e = group.models().objectEnumerator(); e.hasMoreElements();) {
            EOModel model = (EOModel) e.nextElement();
            for (Enumeration e1 = model.entities().objectEnumerator(); e1.hasMoreElements();) {
                EOEntity entity = (EOEntity) e1.nextElement();
                if (entity.userInfo() != null && entity.userInfo().objectForKey(ERXAUDIT_KEYS) != null) {
                    configureEntity(entity);
                }
            }
        }
        log.info("Configuration : " + configuration);
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

    public static String entityNameEncode (EOEnterpriseObject eo) {
        // Get the EncodedEntityName of the object
        // Default to eo's entityName
        String encodedEntityName = eo.entityName();
        EOEntity entity = EOModelGroup.defaultGroup ().entityNamed (eo.entityName ());
        NSDictionary userInfo = entity.userInfo ();
        if (userInfo != null && userInfo.objectForKey (EncodedEntityNameKey) != null)
            encodedEntityName = (String)userInfo.objectForKey (EncodedEntityNameKey);
        return encodedEntityName;
    }
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

            en.hasMoreElements ();) {
              NSArray entities = ((EOModel)en.nextElement ()).entities ();
              for (Enumeration entEn = entities.objectEnumerator ();
              entEn.hasMoreElements ();) {
                EOEntity entity = (EOEntity)entEn.nextElement ();
                NSDictionary userInfo = entity.userInfo ();
                if(userInfo != null) {
                  String encodedEntityName = (String)userInfo.objectForKey (EncodedEntityNameKey);
                  if (encodedEntityName != null)
                    _encodedEntityNames.setObjectForKey (entity.name (), encodedEntityName);
                }
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

      // only use this entity if it has its own table
      if (!ERXEOAccessUtilities.entityUsesSeparateTable(entity)) {
        continue;
      }

      NSDictionary<String, Object> d = entity.userInfo();
      NSMutableArray<String> usedColumns = new NSMutableArray<String>();
      for (Enumeration<String> keys = d.keyEnumerator(); keys.hasMoreElements();) {
        String key = keys.nextElement();
        if (key.startsWith("index")) {
          String numbers = key.substring("index".length());
View Full Code Here

Examples of com.webobjects.eoaccess.EOEntity.userInfo()

    while (modelsEnum.hasMoreElements()) {
      EOModel model = (EOModel) modelsEnum.nextElement();
      Enumeration entitiesEnum = model.entities().objectEnumerator();
      while (entitiesEnum.hasMoreElements()) {
        EOEntity partialExtensionEntity = (EOEntity) entitiesEnum.nextElement();
        NSDictionary userInfo = partialExtensionEntity.userInfo();
        NSDictionary entityModelerDictionary = (NSDictionary) userInfo.objectForKey("_EntityModeler");
        if (entityModelerDictionary != null) {
          String partialEntityName = (String) entityModelerDictionary.objectForKey("partialEntity");
          if (partialEntityName != null) {
            EOEntity partialEntity = modelGroup.entityNamed(partialEntityName);
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.