Package org.openhab.core.converter
Interface ObjectSerializer<T>
- Type Parameters:
T- The object type.
- All Known Subinterfaces:
ItemSerializer,ThingSerializer
- All Known Implementing Classes:
AbstractItemSerializer,AbstractThingSerializer
@NonNullByDefault
public interface ObjectSerializer<T>
A generic interface for serializers that serialize specific object types like Things, Items, Rules etc. into a
serialized representation that is written to an
OutputStream.- Author:
- Ravi Nadahar - Initial contribution
-
Method Summary
Modifier and TypeMethodDescriptionvoidgenerateFormat(String id, OutputStream out) Generate the format for all data that were associated to the provided identifier.Get the name of the format.
-
Method Details
-
getGeneratedFormat
String getGeneratedFormat()Get the name of the format.- Returns:
- The format name.
-
generateFormat
Generate the format for all data that were associated to the provided identifier.- Parameters:
id- the identifier of the format generation.out- TheOutputStreamto write to.
-