[ 
http://issues.apache.org/jira/browse/VELTOOLS-62?page=comments#action_12435358 
] 
            
Nathan Bubna commented on VELTOOLS-62:
--------------------------------------

Interesting.  And yeah, this would be useful.  But i've never been a fan of 
marker interfaces, and in 1.3, i'm actually trying to ditch interfaces in favor 
of looking for a relevant method in reflection.

perhaps we could trade these interfaces for something like a "public Set 
getValidScopes()" method.   the toolbox manager would check for such a method.  
if it existed, then we just do getValidScopes().contains(sti.getScope()) when 
validating the ToolInfo. this would be more inline with the direction 1.3 is 
going. 

what do you think?

of course, long term, i see something like this being done via annotation.

> New empty interfaces that allow one to enforce the scope of a tool
> ------------------------------------------------------------------
>
>                 Key: VELTOOLS-62
>                 URL: http://issues.apache.org/jira/browse/VELTOOLS-62
>             Project: VelocityTools
>          Issue Type: Improvement
>            Reporter: Claude Brisson
>            Priority: Minor
>         Attachments: ApplicationTool.java, RequestTool.java, 
> ServletToolboxManager.patch, SessionTool.java
>
>
> This is a proposal. Once that a tool implements at least one of the three 
> interfaces RequestTool, SessionTool or ApplicationTool, it means that the 
> actual scope of the tool must correspond to one of the interfaces the tool is 
> implementing.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to