Package org.openhab.core.model.yaml
Class AbstractYamlFile
java.lang.Object
org.openhab.core.model.yaml.AbstractYamlFile
- All Implemented Interfaces:
 YamlFile
The 
AbstractYamlFile is the DTO base class used to map a YAML configuration file.
 A YAML configuration file consists of a version and a list of elements.- Author:
 - Laurent Garnier - Initial contribution
 
- 
Field Summary
Fields - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionabstract List<? extends YamlElement>Get the list of elements present in the YAML file.intGet the version present in the YAML file.booleanisValid()Check that the file content is valid. 
- 
Field Details
- 
version
public int versionYAML file version 
 - 
 - 
Constructor Details
- 
AbstractYamlFile
public AbstractYamlFile() 
 - 
 - 
Method Details
- 
getElements
Description copied from interface:YamlFileGet the list of elements present in the YAML file.- Specified by:
 getElementsin interfaceYamlFile- Returns:
 - the list of elements
 
 - 
getVersion
public int getVersion()Description copied from interface:YamlFileGet the version present in the YAML file.- Specified by:
 getVersionin interfaceYamlFile- Returns:
 - the version in the file
 
 - 
isValid
public boolean isValid()Description copied from interface:YamlFileCheck that the file content is valid. It includes the check of duplicated elements (same identifier) and the check of each element. 
 -