• 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
NSArray.iterator and NSArray.listIterator bug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSArray.iterator and NSArray.listIterator bug


  • Subject: NSArray.iterator and NSArray.listIterator bug
  • From: John Larson <email@hidden>
  • Date: Wed, 14 Jun 2006 21:35:17 -0500

Hello all,

can anyone please confirm this as a bug in WebObjects 5.3.1.  When using an NSArray that is a to-many relationship from an entity, the listIterator() method returns an empty list if the NSArray has not had at least count() executed against it.  The same happens when using the iterator() method.

Specifically, my code:

...
scToCopy.toBOM().count();

bom = scToCopy.toBOM().listIterator();


while (bom.hasNext()) {
BOM component = (BOM) bom.next();


...

works, but 

...
// scToCopy.toBOM().count();

bom = scToCopy.toBOM().listIterator();


while (bom.hasNext()) {
BOM component = (BOM) bom.next();


...

does not loop at all.  In the bug list there is issue 4169582 which applied to the iterator() method returning null values.  It still doesn't seem to work for me.  I've doubly confirmed that my install of XCode 2.3 went right and I have 5.3.1 installed.

It appears that whenever the fault is resolved, things go right.  If the object (array) is still a fault, then the method doesn't work.  Calling willReadRelationship doesn't seem to do it either ??  I really don't want to have count() in front of every iterator() call.

Thanks,
John
 _______________________________________________
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: NSArray.iterator and NSArray.listIterator bug
      • From: Chuck Hill <email@hidden>
  • Prev by Date: Solution: Custom namespace in soap response
  • Next by Date: Re: Anybody know what this exception means on startup?
  • Previous by thread: Re: Anybody know what this exception means on startup?
  • Next by thread: Re: NSArray.iterator and NSArray.listIterator bug
  • Index(es):
    • Date
    • Thread