• 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
NSMutableSet, NSArray and WORepetition - Correct Usage
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSMutableSet, NSArray and WORepetition - Correct Usage


  • Subject: NSMutableSet, NSArray and WORepetition - Correct Usage
  • From: "Jonathan Fleming" <email@hidden>
  • Date: Mon, 31 Jan 2005 15:49:34 +0000

I think I'm doing things on the flip side or I have a fried brain...
What is the best way to get a NSMutableSet back into an Array... Why? because I can not use a NSMutableSet in a WORepitition which is calling for a NSArray but more importanly I don't want duplicates in the NSArray.


Or should I be filtering this someother way? Suggustions / examples welcome please. Thanks


this is the code i'm using:

EOFetchSpecification boundFs = new EOFetchSpecification("TbEcmOrder", qualifier, sortOrderings);
EOEditingContext myEC = this.session().defaultEditingContext();
queryResultsOrders = myEC.objectsWithFetchSpecification(boundFs);
queryResultsOrders_distinct = new NSArray (new NSMutableSet(queryResultsOrders));
System.out.println( "===\r NSArray queryResultsOrders_distinct: \r" + queryResultsOrders_distinct);



this is the Error:
Exception occurred while handling request:
java.lang.IllegalArgumentException: While trying to set the field "tbEcmOrder_distinct" on an object of type Ecm_OrderPaymentStatus we expected a TbEcmOrder but received a com.webobjects.foundation.NSMutableSet with a value of ({values = {...found results... }; this = "<TbEcmOrder 21447f _EOIntegralKeyGlobalID[TbEcmOrder (java.lang.Integer)7]>"; }). This often happens if you forget to use a formatter.


I don't understand since I have made this into an NSArray, I belief, but it still seeing a NSMutableSet

Regards
Jonathan :^)

Ummm... Don't blame me, blame my training... ;^)


_______________________________________________ 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: NSMutableSet, NSArray and WORepetition - Correct Usage
      • From: "Arturo Perez" <email@hidden>
  • Prev by Date: Re: WO NewBie
  • Next by Date: Raw Rows versus EOs
  • Previous by thread: Re: WO NewBie
  • Next by thread: Re: NSMutableSet, NSArray and WORepetition - Correct Usage
  • Index(es):
    • Date
    • Thread