Re: [dwr-user] wildcards for include/exclude parameters in converters

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: [dwr-user] wildcards for include/exclude parameters in converters

Mohammad Faisal
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: wildcards for include/exclude parameters in converters

Mike Wilson
Administrator
I think you partly misunderstood but here's an example.
Consider this dwr.xml configuration:

<create creator="new" javascript="Fred">
  <param name="class" value="com.example.Fred"/>
  <exclude method="setWibble"/>
</create>

While reading configuration, DWR will call your addExcludeRule
method with the following arguments:

  addExcludeRule("Fred", "setWibble")

so your implementation can remember the desired security
setting and use them later when the "assert*" methods are
called during method invocation.

Best regards
Mike Wilson

faisal6621 wrote:

> I'd created a class as
>
> package foo.bar.MyAccessControl
>
> import org.directwebremoting.impl.DefaultAccessControl;
>
> public class MyAccessControl
>     extends DefaultAccessControl
> {
>     @Override
>     public void addExcludeRule( String inScriptName, String
> inMethodName )
>     {
> // here I'm supposed to get inScriptName=exclude and
> inMethodName=set* to exclude all setter methods.
> // but how will I get list of setter methods here?
>     }
> }
>
> Thanks and regards
> Mohammad Faisal

Reply | Threaded
Open this post in threaded view
|

Re: [dwr-user] wildcards for include/exclude parameters in converters

david@butterdev.com
In reply to this post by Mohammad Faisal
Take a look at the implementation in DefaultAccessControl.

On 01/28/2015 11:18 PM, [hidden email] wrote:

> I'd created a class as
>
> package foo.bar.MyAccessControl
>
> import org.directwebremoting.impl.DefaultAccessControl;
>
> public class MyAccessControl
>      extends DefaultAccessControl
> {
>      @Override
>      public void addExcludeRule( String inScriptName, String
> inMethodName )
>      {
> // here I'm supposed to get inScriptName=exclude and
> inMethodName=set* to exclude all setter methods.
> // but how will I get list of setter methods here?
>      }
> }
>
> Thanks and regards
> Mohammad Faisal
>