• 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: variable return-classes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: variable return-classes


  • Subject: Re: variable return-classes
  • From: "Adam Chan" <email@hidden>
  • Date: Fri, 5 Sep 2003 13:25:27 -0600

Say you have components C1, C2, C3, and both C1, C2 goto C3. When C3 is
done, page will go back to the caller (C1 or C2).
You can actually pass the caller C1 or C2 (not the name but the actual
WOComponent object) to C3. In other words, you will have a
setCaller(WOComponent c) method in C3.  Once C3 is done, just do a return
caller statement.

Of course there are many other ways. You can also use session to keep track
of the page(WOComponent) flow. Indeed,  session does have a history to
remember the path.

----- Original Message -----
From: "jacques couzteau" <email@hidden>
To: <email@hidden>
Sent: Friday, September 05, 2003 11:21 AM
Subject: variable return-classes


> hello,
>
> I've a a simple qustion which is probably very fundamental for
> programming with java in general.
>
> I made a component which is for editing data of an object from my
> database (a row) called EditStory. This editing component is can be
> called from 2 (may be later more) different other components. For
> instance I have a list view where many rows are shown  (Blog) and
> detailview where only on row is shown at a time (FullStory). Both of
> these can call the edit page 'EditStory'.
>
> After making the changes in the EditView (and saving  them), i want to
> return to the calling component.
>
> My first approach was to pass the name of the calling class as string
> to EditStory. But then i have to do quite inflexible handling of the
> arguments of the calling classes.
>
> So my 2nd idea was to that the calling component passes itself as an
> argument to the EditStory-component. Now I don't know if that is
> possible and how it can be accomplished, since i'm new to java.
>
> Alternatively i was considering to create a new component initialise
> that and then pass the clone as argument (the calling clones itself
> before going to edit and passes this to Edit).
> inside the FullStory-Object:
> FullStory objectToReturnToFromEdit = new FullStory();
> But i get the compiletime error message: cannot resolve symbol:
> construtor Fullstory(ec);
>
> I don't know which way is best (easiest, cleanest and sevest)
>
> can someone explain?
>
> 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.
_______________________________________________
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: variable return-classes
      • From: jacques couzteau <email@hidden>
References: 
 >variable return-classes (From: jacques couzteau <email@hidden>)

  • Prev by Date: Re: Comparing 2 Arrays if they have same objects
  • Next by Date: Looking for Mac Programmers
  • Previous by thread: variable return-classes
  • Next by thread: Re: variable return-classes
  • Index(es):
    • Date
    • Thread