Package org.openhab.core.converter
Interface ObjectParser<T>
- Type Parameters:
T- The object type.
- All Known Subinterfaces:
ItemParser,ThingParser
@NonNullByDefault
public interface ObjectParser<T>
A generic interface for parsers that parse strings into specific object types like Things, Items, Rules etc.
- Author:
- Ravi Nadahar - Initial contribution
-
Method Summary
Modifier and TypeMethodDescriptionvoidfinishParsingFormat(String modelName) Release the resources from a previously started format parsing.getParsedObjects(String modelName) Get the objects found when parsing the format.Get the name of the format.@Nullable StringParse the provided syntax in format without impacting any object registries.
-
Method Details
-
getParserFormat
String getParserFormat()Get the name of the format.- Returns:
- The format name.
-
startParsingFormat
Parse the provided syntax in format without impacting any object registries. -
getParsedObjects
Get the objects found when parsing the format.- Parameters:
modelName- the model name whose objects to get.- Returns:
- The
Collectionof objects.
-
finishParsingFormat
Release the resources from a previously started format parsing.- Parameters:
modelName- the model name whose resources to release.
-