Re: WOLips questions
Re: WOLips questions
- Subject: Re: WOLips questions
- From: Paul Hoadley <email@hidden>
- Date: Sat, 30 Sep 2017 10:15:48 +0930
Hi André,
On 29 Sep 2017, at 9:17 pm, André Rothe <email@hidden> wrote:
> I would like to know, where WebObjects defines, that the method
> DirectAction.defaultAction() will be called? There the Main component will be
> set as next (first) page, as I understand.
The Main component is hard-wired (as a magic string “Main”) in at least a
couple of places:
* WODirectAction.defaultAction()
* WOApplication.pageWithName(String aName, WOContext aContext)
In the latter case, WOApplication tries to instantiate the "Main" component if
aName is null. So if your goal is to ensure that some other component than Main
is the default page, you should override both of those methods. pageWithName()
can handle null as a special case, and otherwise return super.pageWithName().
> Can I configure another name of the default DirectAction class in my project?
If you mean can you configure some method other than defaultAction() to be the
default action, that’s obviously a slightly different goal. Other than
overriding the defaultAction() method, I don’t know of a way to “configure”
that, no.
--
Paul Hoadley
https://logicsquad.net/
https://www.linkedin.com/company/logic-squad/
_______________________________________________
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