Thanks Jeromy...

There is not any document about this one.. 
So i missed that feature...



Jeromy Evans - Blue Sky Minds wrote:
> 
> Ryan Wong wrote:
>> I have changed the rest action mapper class to apply Ruby Style .
>> there is draft, post here to find a better way to build RESTful app with
>> struts2
>>
>>   
>  
> I thought the RestActionMapper was already a copy of the RoR 
> convention?  I think it already matches all your mappings except "new" 
> is called "editNew". I'm no expert though.
> 
>> Besides, you could use Parameters and Parameter annotations with Regular
>> Expression to support custom url pattern and Request Parameter Mapping.
>> @Parameters( { @Parameter(pattern = "page/(\\w+)", property = "page") })
>> public class TopicsController(){ }
>>
>> thus,
>>
>>   get http://localhost/namespace/controller/page/1
>>  
>>
>> will call controller's index() method with parameter {page=1} 
>>
>>   
> 
> Sounds interesting. While it makes for a nice URL, some may argue 
> against including params for a resource like this..
> For params before the Controller (in the namespace) you may appreciate 
> the NamedVariablePatternMatcher.
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 


-----
Blog: http://www.ryanwong.name
Can Use: English, Chinese
-- 
View this message in context: 
http://www.nabble.com/Some-Idea-On-REST-mapping-tp19263471p19270183.html
Sent from the Struts - User mailing list archive at Nabble.com.


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

Reply via email to