• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: WONDER on Windows
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: WONDER on Windows


  • Subject: Re: WONDER on Windows
  • From: Ron X <email@hidden>
  • Date: Tue, 22 May 2012 16:41:09 +0300

method:

    public synchronized static EOEntity prepareExtraEntityForEntityNamed(EOEditingContext ec, String entityName) {
        String newEntityName = EXTRA_ENTITY_NAME_PREFIX+entityName;
        EOEntity result = ERXEOAccessUtilities.entityNamed(ec, newEntityName);
        if (result==null) {
            EOEntity entity = ERXEOAccessUtilities.entityNamed(ec, entityName);
            EOModel model = entity.model();
            java.net.URL modelPath = model.pathURL();
            if(log.isDebugEnabled()) log.debug("extraEntityForEntityNamed: modelPath="+modelPath);
           
            try {
                java.net.URI entityPath = new java.net.URI(NSPathUtilities.stringByAppendingPathComponent(modelPath.toString(), entityName+".plist"));
                if(log.isDebugEnabled()) log.debug("extraEntityForEntityNamed: entityPath="+entityPath);
                NSMutableDictionary entityDictionary = NSPropertyListSerialization.dictionaryForString(ERXFileUtilities.stringFromFile(new File(entityPath))).mutableClone();
                if(log.isDebugEnabled()) log.debug("extraEntityForEntityNamed: entityDictionary="+entityDictionary);
               
                entityDictionary.setObjectForKey(newEntityName, "name");
                entityDictionary.setObjectForKey("EOGenericRecord", "className");
               
                result = new EOEntity(entityDictionary, model);
                result.awakeWithPropertyList(entityDictionary);
                // result.setClassName(entity.className());
                model.addEntity(result);
            } catch (Exception e) {
            /*  _exception there >>>>_ */ log.error("prepareExtraEntityForEntityNamed: exception="+e);
            }
            // create fss
            java.util.Enumeration enumerator = entity.fetchSpecificationNames().objectEnumerator();
            while (enumerator.hasMoreElements()) {
                String fsName = (String)enumerator.nextElement();
                EOFetchSpecification fs = (EOFetchSpecification)entity.fetchSpecificationNamed(fsName).clone();
                fs.setEntityName(newEntityName);
                result.addFetchSpecification(fs, fsName);
            }
           
            if(log.isDebugEnabled()) {
                log.debug("extraEntityForEntityNamed: result.fetchSpecificationNames()="+result.fetchSpecificationNames());
                log.debug("extraEntityForEntityNamed: result.attributes()="+result.attributes());
                log.debug("extraEntityForEntityNamed: result.relationships()="+result.relationships());
            }
        }
        return result;
    }

2012/5/22 Pascal Robert <email@hidden>
Full strack trace please, DMEOAccessUtilities is not part of Wonder, so we can't figure out what Wonder or WO method you are calling.

> hi
> i have some difficuilts with start of app:
>
> ERROR (DMEOAccessUtilities.java:332) - prepareExtraEntityForEntityNamed: exception=java.net.URISyntaxException: Illegal character in path at index 162: file:/C:/Users/ronx/workspace/svn/trunk/Frameworks/ApplicationsFrameworks/LSBL/build/LSBL.framework/Resources/ls.eomodeld\Album.plist
>
> could anyone help?
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: WONDER on Windows
      • From: Mike Schrag <email@hidden>
    • Re: WONDER on Windows
      • From: Pascal Robert <email@hidden>
References: 
 >WONDER on Windows (From: Ron X <email@hidden>)
 >Re: WONDER on Windows (From: Pascal Robert <email@hidden>)

  • Prev by Date: Re: REST APIs in WO applications
  • Next by Date: Re: WONDER on Windows
  • Previous by thread: Re: WONDER on Windows
  • Next by thread: Re: WONDER on Windows
  • Index(es):
    • Date
    • Thread