Interface Processor<V>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Performs a transformation on a value annotated with a specific type.
- Since:
- 4.0.0
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceProcessor.Factory<A extends Annotation,T> Provider to, given an annotation instance and the type it's on, create aProcessor. -
Method Summary
Modifier and TypeMethodDescriptionstatic Processor.Factory<Comment,Object> comments()Apply comments fromCommentannotation on save.static Processor.Factory<Comment,Object> localizedComments(ResourceBundle source) Apply localized comments fromCommentannotation on save.voidprocess(V value, ConfigurationNode destination) Transform the output node on write.
-
Method Details
-
process
Transform the output node on write.- Parameters:
value- source valuedestination- destination node- Since:
- 4.0.0
-
comments
Apply comments fromCommentannotation on save.- Returns:
- a new processor factory
- Since:
- 4.0.0
-
localizedComments
Apply localized comments fromCommentannotation on save.The
comment's valuewill be treated as a key intosource, resolved to the system default locale. Missing keys will be written literally to node.- Parameters:
source- source bundle for comments- Returns:
- a new processor factory
- Since:
- 4.0.0
-