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
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
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
Can anyone explain how to use the MethodReturningConverter?