[ 
http://jira.codehaus.org/browse/JBEHAVE-264?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=216609#action_216609
 ] 

Bruno Bieth commented on JBEHAVE-264:
-------------------------------------

Forgot to mention that this will only work with JBEHAVE-263 fixed.

> Steps could act as parameter converters : add the @ParameterConverter 
> annotation
> --------------------------------------------------------------------------------
>
>                 Key: JBEHAVE-264
>                 URL: http://jira.codehaus.org/browse/JBEHAVE-264
>             Project: JBehave
>          Issue Type: Improvement
>            Reporter: Bruno Bieth
>         Attachments: ParameterConverterStepsFactory.java
>
>
> Better starting with an example :
> {code}
> Given a series
>       - Name : Series 0110
>       - NAV : $200
> Given an investor Peter
> When Peter invests 7500 shares in series Series 0110
> Then ...
> {code}
> It would be interesting to have the Steps definition class also able to 
> provide some converters. This is what the code could look like :
> {code}
> @ParameterConverter
> public Person findByFirstName( String firstName ) {
>       return personDao.findByFirstName( firstName ); 
> }
> @When("$person invests $nbShares shares in series $series" )
> public void invest(Person person, int nbShares, Series series ) {
> }     
> {code}
> I've attached the ParameterConverterStepsFactory as it's getting bigger.

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

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to