--- Ted Husted <[EMAIL PROTECTED]> wrote: > Steve Raeburn wrote: > > SuccessAction does already exist in Scaffold. That version is slightly > > different as it uses the Tokens constants class. I don't really see > what > > that would buy us, as the user would still need to know what name to > enter > > for the ActionForward. I wouldn't want to tie a core Action to the > scaffold > > package and if we added the constant to Globals it just makes it > harder for > > the user to figure out what to name his ActionForward. (Imagine the > > Javadoc - "This action forwards to an ActionForward specified by the > value > > of the org.apache.struts.Globals.SUCCESS constant" vs. "This action > forwards > > to an ActionForward named "success".) > > Actually, I would say that we should provide "success" and "failure" as > standard tokens in the Global class. We are forever saying that most > Actions only need success and failure to make do. And, I for one, have > sworn off *ever* using a inline static String in production code. Rather > > than expect everyone to reinvent the wheel by defining "success" and > "failure" in their own applications, we should just provide it as a > convenience.
Not everyone uses the terms "success" and "failure" in their apps and hardcoding these into Struts is *not* a good idea. It's an extremely small wheel to reinvent public static final String SUCCESS = "blah"; :-). I still don't see a need for a SuccessAction in the first place. Why is it any better than using a ForwardAction? David > > Of course, I realize that these are English words. But, so are "true" > and "false", and the Java platform defines these as String statics, and > we should feel free to do the same with "success" and "failure". > Virtually every Struts example program uses these tokens, and we should > just get real and make them globals. > > As for the JavaDoc issues, we already have to do this with everything > else, like what key attribute the locale property is stored under in the > > session context. > > Meanwhile, if there is anything anyone wants to move or copy from > Scaffold to the core distribution, please feel free. =:) > > -Ted. > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]