Hi André,

Invalidating the GlobalIds won’t work.  That will just refresh the objects that 
you have a list of already.  From your description, I think that you want to 
refresh what is in list (get an updated list with inserted and deleted rows 
that match the databse).  This should work
ERXEOControlUtilities. clearSnapshotForRelationshipNamed(eo, " extWsProjects ");

Following that you many need to refault the objects in the relationship.



On 2018-03-05, 8:31 AM, "Webobjects-dev on behalf of André Rothe" 
<webobjects-dev-bounces+chill=gevityinc....@lists.apple.com on behalf of 
andre.ro...@zks.uni-leipzig.de> wrote:

    Hi,
    
    I have an EO with a relationship to a second EO. The database in the
    background will be changed by another application, so it will be
    necessary to refetch the associated EOs of the relationship on every
    access.
    
    How I can invalidate the list of the associated EOs?
    
    This is the generated method (EOGenerator):
    
    public NSArray<ExtWsProject> extWsProjects() {
     // TODO: invalidate this array
     return (NSArray<ExtWsProject>)storedValueForKey("extWsProjects");
    }
    
    On the page
    https://en.wikibooks.org/wiki/WebObjects/EOF/Using_EOF/Caching_and_Freshness
    
    I read something from Jesse Barnum, should I get all the ExtWsProject
    objects and their GIDs to call ec.invalidateObjectsWithGlobalIDs(ids) to
    make faults?
    
    But what about deleted rows in the database, the other application can
    also delete rows, so the faults should not be necessary?
    
    Thanks a lot
    Andre
    
     _______________________________________________
    Do not post admin requests to the list. They will be ignored.
    Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
    Help/Unsubscribe/Update your Subscription:
    https://lists.apple.com/mailman/options/webobjects-dev/chill%40gevityinc.com
    
    This email sent to ch...@gevityinc.com
    

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to