Andrey Mashenkov created IGNITE-15787:
-----------------------------------------
Summary: Mapper builder annotations.
Key: IGNITE-15787
URL: https://issues.apache.org/jira/browse/IGNITE-15787
Project: Ignite
Issue Type: Sub-task
Reporter: Andrey Mashenkov
Let's introduce annotation for mapper builder.
Suggested annotations:
* Transient - that makes mapper ignore the marked field. Field data will not be
saved into a table.
* Column(String) - maps field to a field of the given name.
* Column(String, Class) - maps field to a field of given name using converter
class.
This will allow users to create mapper like this
{code:java}
Mappers.for(Record.class)
{code}
instead of like this
{code:java}
Mappers.of(TruncatedRecord.class)
.map("field",
(obj) -> Marshaller.marshal(obj),
(row) -> Marshaller.unmarshal(row)
);
{code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)