No, it's not scoped to a specific step class. Methods annotated by @AsParameterConverter are collected, transformed into MethodReturnConverters and can be used anywhere the return type is matched. Like any other converter, you can register as many as you want accepting a given type, but only the first one that is accepted will be used when iterating over all the registered ones.

On 30/05/2014 18:02, Frank Pedroza wrote:
I think what you're showing here is how to define a converter that is scoped to a specific step class rather than any and all step classes or would this converter get used whenever a Calendar was the expected parameter type? If the later, does this mean that I can only register a single converter for a given type? Alternatively, do all the registered converters get iterated over and asked if they can handle a given type and, if so, given the opportunity to do the conversion?


On Fri, May 30, 2014 at 12:53 AM, Mauro Talevi <[email protected] <mailto:[email protected]>> wrote:

    You don't use it directly.  Use @AsParameterConverter annotation:

    
https://github.com/jbehave/jbehave-core/blob/master/examples/core/src/main/java/org/jbehave/examples/core/steps/CalendarSteps.java



    On 30/05/2014 01:27, Frank Pedroza wrote:

        Can anyone explain how to use the MethodReturningConverter?



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

    http://xircles.codehaus.org/manage_email





--
--------------------------------------------
Frank M. Pedroza  -  Software Engineer
Partnet  -  Development
801.708.5050

-----------------------------------------------------------------
The nice part about being a pessimist is that you are constantly being either proven right or pleasantly surprised.
-- George F. Will

Reply via email to