Package org.loxlylabs.nestedtext
Interface NestedText.Adapter<T>
- Type Parameters:
T- The type to adapt.
- Enclosing class:
NestedText
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A functional interface for providing a custom serialization strategy for a specific class.
This is useful for types that the default reflection-based serializer cannot handle correctly.
-
Method Summary
Modifier and TypeMethodDescriptiontoNestedTextValue(T value) Converts a given value of type T into a NestedText-compatible object.
-
Method Details
-
toNestedTextValue
Converts a given value of type T into a NestedText-compatible object. The returned object should be aString,Map, orCollection.- Parameters:
value- The object to convert.- Returns:
- The NestedText-compatible representation of the value.
-