GreenPepper Core
TypeConversion changes
The order of priority of the TypeConversion has been changed to be more functionnal and logical.
Before the priorities were (for the parsing method):
- if the Class defined a static T parse(String value) , it was used
- otherwise the developers registered Converters were used
- at last, it the Class defined a static T valueOf(String value) , it was used .
Now suppose that you wanted to convert to a LocalDateTime.
The LocalDateTime class, from version 2.0 defines a method static T parse(String value) where value should be in ISO format.
In the order of precedence you would have been forced to use the full ISO format in your page.
With version 4.0.1+ of GreenPepper, the order is the following :
- at first the developers registered Converters will be used
- then if the Class defined a static T parse(String value) , it was used
- at last, it the Class defined a static T valueOf(String value) , it was used .
This means that you will be able to override any parse method behavior now.
More Information in the documentation
GreenPepper Atlassian repository
- When retrieving a page, if the content type is not set, we will default to "text/html;charset=UTF8" .
- Any <base/> tag in the page will be removed to prevent breaking the usage of anchors.
0 Comments