No, because the validation files are named

ClassName-validationContext-validation.xml

Therefore the context is just a further specifier on top of the class
name. All of the validations are class specific, with class defaults in

ClassName-validation.xml

And have more specific validations which are added to these defaults in
the context specific files. You can also make the validation context for
visitor validations be different from the context passed in from the
outer Action by specifying a context param. I should probably make it
where you can specify the context in the interceptor reference too...
Hmm... Well, I've got to have something to add for 1.1 :-)

Jason

> -----Original Message-----
> From: Tim Dwelle [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, December 02, 2003 10:54 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [OS-webwork] [XWork] Howto use validation 
> framework with plain JavaBeans (no Actions)
> 
> 
> In the code snippet below, the context string = the action name.
> 
> Doesn't that mean that if 2 actions (of the same class) have 
> the same name, but live in different namespaces, that they 
> have to use the same validation?
> 
> Wouldn't it be better if the context string contained the 
> namespace as well?
> 
> 
> -Tim.
> 
> 
> ----- Original Message ----- 
> From: "Jason Carreira" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, December 02, 2003 4:45 PM
> Subject: RE: [OS-webwork] [XWork] Howto use validation 
> framework with plain JavaBeans (no Actions)
> 
> 
> > Yep...
> >
> > Here's the before() method from the ValidationInterceptor:
> >
> >     protected void before(ActionInvocation invocation) throws 
> > Exception {
> >         Action action = invocation.getAction();
> >         String context = invocation.getProxy().getActionName();
> >
> >         if (log.isDebugEnabled()) {
> >             log.debug("Validating " +
> > invocation.getProxy().getNamespace() +
> > invocation.getProxy().getActionName() + ".");
> >         }
> >
> >         ActionValidatorManager.validate(action, context);
> >     }
> >
> > There's nothing special about the action or the context here... It 
> > could be any bean and String context name.
> >
> > Jason
> >
> > > -----Original Message-----
> > > From: Torsten Juergeleit [mailto:[EMAIL PROTECTED]
> > > Sent: Tuesday, December 02, 2003 4:38 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: [OS-webwork] [XWork] Howto use validation framework with 
> > > plain JavaBeans (no Actions)
> > >
> > >
> > > Is XWork's validation framework usable with
> > > non-actions (e.g. POJOs or JavaBeans) too?
> > >
> > > If yes, where can I find sample code?
> > >
> > > Cheers,
> > > Torsten
> > >
> > > __________________________________
> > > Do you Yahoo!?
> > > Free Pop-Up Blocker - Get it now http://companion.yahoo.com/
> > >
> > >
> > > -------------------------------------------------------
> > > This SF.net email is sponsored by: SF.net Giveback Program.
> > > Does SourceForge.net help you be more productive?  Does it
> > > help you create better code?  SHARE THE LOVE, and help us
> > > help YOU!  Click Here: http://sourceforge.net/donate/
> > > _______________________________________________
> > > Opensymphony-webwork mailing list
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> > >
> >
> >
> > -------------------------------------------------------
> > This SF.net email is sponsored by: SF.net Giveback Program.
> > Does SourceForge.net help you be more productive?  Does it
> > help you create better code?  SHARE THE LOVE, and help us help
> > YOU!  Click Here: http://sourceforge.net/donate/
> > _______________________________________________
> > Opensymphony-webwork mailing list
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: SF.net Giveback Program.
> Does SourceForge.net help you be more productive?  Does it
> help you create better code?  SHARE THE LOVE, and help us help
> YOU!  Click Here: http://sourceforge.net/donate/
> _______________________________________________
> Opensymphony-webwork mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> 


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork

Reply via email to