public final class ConfigurateTranslator extends Object implements DataTranslator<ConfigurationNode>
DataView
s into ConfigurationNode
s.Modifier and Type | Method and Description |
---|---|
static ConfigurateTranslator |
instance()
Get the instance of this translator.
|
void |
translateContainerToData(ConfigurationNode node,
DataView container)
Translates the given
DataView into the given data structure. |
ConfigurationNode |
translateData(DataView container)
Translates the given
DataView into the type of data structure. |
DataView |
translateFrom(ConfigurationNode node)
Translates the given data structure into a usable
DataView that
can be used with the rest of DataAPI. |
public static ConfigurateTranslator instance()
public ConfigurationNode translateData(DataView container)
DataTranslator
DataView
into the type of data structure.translateData
in interface DataTranslator<ConfigurationNode>
container
- The container to translatepublic void translateContainerToData(ConfigurationNode node, DataView container)
DataTranslator
DataView
into the given data structure.
This assumes that the given data structure will be the top level node
of the data contained in the DataView
.
translateContainerToData
in interface DataTranslator<ConfigurationNode>
node
- The node to store datacontainer
- The container of data to translatepublic DataView translateFrom(ConfigurationNode node)
DataTranslator
DataView
that
can be used with the rest of DataAPI.translateFrom
in interface DataTranslator<ConfigurationNode>
node
- The data structure containing raw dataDataView