-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Register Converters for Offset java.time types in Jsr310Converters #2681
Conversation
We now appropriately handle OffsetDateTime and OffsetTime the same as all other java.time types, supported as simple types on Spring application (persistent) entity classes. Closes #2677
new BinaryConverters.StringToBytesConverter(), | ||
new BinaryConverters.BytesToStringConverter(), | ||
new BinaryConverters.NumberToBytesConverter(), | ||
new BinaryConverters.BytesToNumberConverterFactory(), | ||
new BinaryConverters.EnumToBytesConverter(), | ||
new BinaryConverters.BytesToEnumConverterFactory(), | ||
new BinaryConverters.BooleanToBytesConverter(), | ||
new BinaryConverters.BytesToBooleanConverter(), | ||
new BinaryConverters.DateToBytesConverter(), | ||
new BinaryConverters.BytesToDateConverter(), | ||
new BinaryConverters.UuidToBytesConverter(), | ||
new BinaryConverters.BytesToUuidConverter() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can drop the extra BinaryConverters.
part here.
@@ -58,6 +61,7 @@ public abstract class Jsr310Converters { | |||
} | |||
|
|||
List<Converter<?, ?>> converters = new ArrayList<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could be changed to List.of
or initialized with an initial size.
@@ -296,4 +304,51 @@ public Duration convert(byte[] source) { | |||
} | |||
} | |||
|
|||
/** | |||
* @author John Blum | |||
* @see java.time.OffsetDateTime |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
though not a public
class, having a @since
tag can help with code forensic
That's merged, polished, and backported now. |
See #2677