• 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: strange behaviour with items in WORepition
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: strange behaviour with items in WORepition


  • Subject: Re: strange behaviour with items in WORepition
  • From: jacques couzteau <email@hidden>
  • Date: Thu, 11 Sep 2003 21:20:59 +0200

Am Dienstag, 09.09.03, um 22:58 Uhr (Europe/Berlin) schrieb Arturo Pirez:

On Tuesday, September 9, 2003, at 10:08  AM, jacques couzteau wrote:

hello everyone,
i'm using a WORepition in 2 different components. In the first, called Strories, i'm looping through an NSArray that contains all my stories and displays its short version and a couple of other things.


With each story there are two associated links:

To accomplish that i wrote a checkUser method in session which comes in two flavours:
1. One for comparing the user with the story author
2. One for comparing the user with the comment author
It is called from a method within each component with the story or comment in question as argument.


Now the strange part:
when i loop through the NSArray of Stories the checkuser method works fine. But when i loop through story.commentss in the comment-component the item is null, even though i'm using it in many other places within the component for displaying other things such as checkin-time and change-time. which works fine, so i know that the item isn't really null. it just seems as if the method doesn't have access to it.


That is very odd. Can you give me details as to exactly what you're doing and how? That is, are you using an action on the Hyperlink etc? Why did you put those methods in session?

actually the checkUser in session is acessed through a wrapper methog in the componentclass. i felt that's the best way to do it, because
1. i didn't need to double code
2. i didn't know how to attach a boolean function from session to a conditional. actually my action list for the session-object shows only those functions that return void.


it's a method that needs to be accessed from different components. so it doesn't belong in either of the component. because i was too lazy to introduce a new class for shared methods i put them in session. i hope this is a proper way to do that.

i introduced a private variable in the storyView Class to circumvent the error and continued to develop my app. i didn't like it very much because was boubling data. now i removed that variable again but the problem didn't come back, which is alright with me. :)

so thank you for your effort. i suppose i had some error that i fixed when i was changing other code.

sorry for my late reply. i was busy doing other things


greetz

couzteau
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: strange behaviour with items in WORepition
      • From: "Nathan C. Hampton" <email@hidden>
References: 
 >Re: strange behaviour with items in WORepition (From: Arturo PĂ©rez <email@hidden>)

  • Prev by Date: bug with WOContext.completeURLWithRequestHandlerKey
  • Next by Date: Re: bug with WOContext.completeURLWithRequestHandlerKey
  • Previous by thread: Re: strange behaviour with items in WORepition
  • Next by thread: Re: strange behaviour with items in WORepition
  • Index(es):
    • Date
    • Thread