Interface ImmutableResourceProperties
- All Superinterfaces:
AnnotatorAccessor, Containable, DelimiterAccessor, EmptyAccessor, ImmutableCanonicalTable, ImmutableInterOperableTable<String>, ImmutablePathTable<String>, ImmutableProperties, ImmutableTable<String,String>, Keys<String, String>, TypeAccessor<String>
- All Known Subinterfaces:
ImmutableResourceProperties.MutableResoureProperties, ImmutableScheduledResourceProperties, ImmutableScheduledResourceProperties.ScheduledMuableResourceProperties, ResourceProperties, ScheduledResourceProperties
- All Known Implementing Classes:
AbstractImmutableResourcePropertiesDecorator, AbstractResourceProperties, AbstractResourcePropertiesDecorator, ImmutableScheduledResourcePropertiesDecorator, JavaProperties, JsonProperties, PolyglotProperties, ScheduledResourcePropertiesDecorator, TomlProperties, UnmodifyableResourceProperties, XmlProperties, YamlProperties
The
ImmutableResourceProperties are a
https://www.metacodes.proization of the ImmutableTable.
ImmutableProperties represent a collection of String key and
String value pairs as properties usually occur in pure text form, to
be converted to the required data types. For this reason, the
ImmutableResourceProperties interface provides additional conversion
methods. When parsing properties from notations which do not support nodes to
have values as well as child elements, then please support one of the
identifiers contained in the THIS_ATTRIBUTES array.-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceThe interfaceImmutableResourceProperties.MutableResourePropertiesdefines "dirty" methods allowing to modify ("mutate") theImmutableResourceProperties.Nested classes/interfaces inherited from interface AnnotatorAccessor
AnnotatorAccessor.AnnotatorBuilder<B>, AnnotatorAccessor.AnnotatorMutator, AnnotatorAccessor.AnnotatorPropertyNested classes/interfaces inherited from interface DelimiterAccessor
DelimiterAccessor.DelimiterBuilder<B>, DelimiterAccessor.DelimiterMutator, DelimiterAccessor.DelimiterPropertyNested classes/interfaces inherited from interface EmptyAccessor
EmptyAccessor.EmptyBuilder<B>, EmptyAccessor.EmptyMutator, EmptyAccessor.EmptyPropertyNested classes/interfaces inherited from interface ImmutableCanonicalTable
ImmutableCanonicalTable.MutableCanonicalTableNested classes/interfaces inherited from interface ImmutableInterOperableTable
ImmutableInterOperableTable.MutableInterOperableTable<T>Nested classes/interfaces inherited from interface ImmutablePathTable
ImmutablePathTable.MutablePathTable<T>Nested classes/interfaces inherited from interface ImmutableProperties
ImmutableProperties.MutablePropertiesNested classes/interfaces inherited from interface ImmutableTable
ImmutableTable.MutableTable<K,V> Nested classes/interfaces inherited from interface Keys
Keys.MutableKeys<K,V>, Keys.MutableValues<K, V> Nested classes/interfaces inherited from interface TypeAccessor
TypeAccessor.TypeBuilder<T,B>, TypeAccessor.TypeMutator<T>, TypeAccessor.TypeProperty<T> -
Field Summary
Fields inherited from interface ImmutablePathTable
ANNOTATOR, DELIMITERFields inherited from interface ImmutableProperties
DEFAULT_COMMENT -
Method Summary
Modifier and TypeMethodDescriptionreload()Reloads theImmutableResourcePropertiesfrom the resource to which theImmutableResourcePropertiesare attached to (such as aFileas ofImmutableResourceProperties.MutableResoureProperties.loadFrom(File)orImmutableResourceProperties.MutableResoureProperties.saveTo(File)).reload(ReloadMode aReloadMode) Reloads theImmutableResourcePropertiesfrom the resource to which theImmutableResourcePropertiesare attached to (such as aFileas ofImmutableResourceProperties.MutableResoureProperties.loadFrom(File)orImmutableResourceProperties.MutableResoureProperties.saveTo(File)).default StringProduces the external representation of the properties as of the serialized format supported by the implementing class.toSerialized(DocumentOptions aOptions) Produces the external representation of the properties as of the serialized format supported by the implementing class.Methods inherited from interface Containable
sizeMethods inherited from interface EmptyAccessor
isEmptyMethods inherited from interface ImmutableCanonicalTable
asArray, asArray, asArray, asArray, asBooleanArray, asBooleanArray, asBooleanArray, asBooleanArray, asByteArray, asByteArray, asByteArray, asByteArray, asCharArray, asCharArray, asCharArray, asCharArray, asDoubleArray, asDoubleArray, asDoubleArray, asDoubleArray, asFloatArray, asFloatArray, asFloatArray, asFloatArray, asIntArray, asIntArray, asIntArray, asIntArray, asLongArray, asLongArray, asLongArray, asLongArray, asShortArray, asShortArray, asShortArray, asShortArray, queryBetween, toMap, toPropertiesMethods inherited from interface ImmutableInterOperableTable
getBoolean, getBoolean, getBoolean, getBoolean, getBoolean, getBooleanOr, getBooleanOr, getBooleanOr, getBooleanOr, getBooleanOr, getByte, getByte, getByte, getByte, getByte, getByteOr, getByteOr, getByteOr, getByteOr, getByteOr, getChar, getChar, getChar, getChar, getChar, getCharOr, getCharOr, getCharOr, getCharOr, getCharOr, getClass, getClass, getClass, getClass, getClass, getClassOr, getClassOr, getClassOr, getClassOr, getClassOr, getDouble, getDouble, getDouble, getDouble, getDouble, getDoubleOr, getDoubleOr, getDoubleOr, getDoubleOr, getDoubleOr, getEnum, getEnum, getEnum, getEnum, getEnum, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getEnumOr, getFloat, getFloat, getFloat, getFloat, getFloat, getFloatOr, getFloatOr, getFloatOr, getFloatOr, getFloatOr, getInt, getInt, getInt, getInt, getInt, getIntOr, getIntOr, getIntOr, getIntOr, getIntOr, getLong, getLong, getLong, getLong, getLong, getLongOr, getLongOr, getLongOr, getLongOr, getLongOr, getShort, getShort, getShort, getShort, getShort, getShortOr, getShortOr, getShortOr, getShortOr, getShortOr, getString, getString, getString, getString, getString, getStringOr, getStringOr, getStringOr, getStringOr, getStringOrMethods inherited from interface ImmutablePathTable
children, children, children, children, children, children, containsKey, containsKey, containsKey, dirs, dirs, dirs, dirs, dirs, dirs, findPaths, fromExternalPath, get, get, get, getArray, getArray, getArray, getArray, getArray, getArray, getArrayIndexes, getArrayIndexes, getArrayIndexes, getArrayIndexes, getArrayIndexes, getArrayOr, getArrayOr, getArrayOr, getArrayOr, getArrayOr, getArrayOr, getDirIndexes, getDirIndexes, getDirIndexes, getDirIndexes, getDirIndexes, getDirIndexes, getRootPath, getValueAt, getValueAt, getValueAt, getValueAt, getValueAt, getValueAt, hasChildren, hasChildren, hasChildren, hasChildren, hasChildren, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasDirAt, hasParentPath, hasPath, hasPath, hasPath, hasPath, hasPath, hasSubDirs, hasSubDirs, hasSubDirs, hasSubDirs, hasValue, hasValue, hasValue, hasValue, hasValue, hasValueAt, hasValueAt, hasValueAt, hasValueAt, hasValueAt, hasValueAt, hasValueAt, hasValueAt, isArray, isArray, isArray, isArray, isArray, isArray, isChild, isChild, isChild, isChild, isDir, isDir, isDir, isDir, isDir, isEqualTo, isIndexDir, isIndexDir, isIndexDir, isIndexDir, isIndexDir, isLeaf, isLeaf, isLeaf, isLeaf, isLeaf, isRootPath, keySet, keySet, keySet, keySet, keySet, lastArrayIndex, lastArrayIndex, lastArrayIndex, lastArrayIndex, lastArrayIndex, lastArrayIndex, lastDirIndex, lastDirIndex, lastDirIndex, lastDirIndex, lastDirIndex, lastDirIndex, leaves, leaves, leaves, leaves, leaves, leaves, nextArrayIndex, nextArrayIndex, nextArrayIndex, nextArrayIndex, nextArrayIndex, nextArrayIndex, nextDirIndex, nextDirIndex, nextDirIndex, nextDirIndex, nextDirIndex, nextDirIndex, paths, paths, paths, paths, paths, paths, queryPaths, queryPaths, queryPaths, queryPaths, queryPaths, queryPaths, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, sortedKeys, toDataStructure, toDataStructure, toExternalPath, toInstance, toInstance, toLeaf, toMap, toNormalizedPath, toParentPath, toPath, toPath, toPath, toPath, toPathElements, toPathList, toPathStack, toPrintable, toPropertyPath, toType, toType, toType, toType, toType, toType, toType, toTypeMethods inherited from interface ImmutableProperties
containsValue, getAnnotator, getDelimiter, getDir, getDir, getDir, getDir, getDir, getDirAt, getDirAt, getDirAt, getDirAt, getDirAt, getDirAt, getDirs, getDirs, getDirs, getDirs, getDirs, getType, query, query, query, query, query, queryBetween, queryBetween, queryBetween, queryBetween, queryBetween, queryFrom, queryFrom, queryFrom, queryFrom, queryFrom, queryFrom, queryTo, queryTo, queryTo, queryTo, queryTo, queryTo, retrieveBetween, retrieveBetween, retrieveBetween, retrieveBetween, retrieveBetween, retrieveFrom, retrieveFrom, retrieveFrom, retrieveFrom, retrieveFrom, retrieveTo, retrieveTo, retrieveTo, retrieveTo, retrieveTo
-
Method Details
-
reload
Reloads theImmutableResourcePropertiesfrom the resource to which theImmutableResourcePropertiesare attached to (such as aFileas ofImmutableResourceProperties.MutableResoureProperties.loadFrom(File)orImmutableResourceProperties.MutableResoureProperties.saveTo(File)). In case the resource (such as anInputStream) does not support reloading, then anIllegalStateExceptionis thrown. ImmutableProperties existing in the attached resource as well in theImmutablePropertiesitself are replaced. ImmutableProperties existing in the attached resource but not(!) in theImmutablePropertiesitself are not(!) removed. Usereload(ReloadMode)with an argument oftrue(~ orphan removal) to remove properties not existing in the resource.- Returns:
- The
ImmutablePropertiesas loaded from the resource and applied to this instance. - Throws:
IOException- thrown in case accessing the resource encountered an I/O problem.ParseException- Signals that an error has been reached unexpectedly while parsing the data to be loaded.IllegalStateException- in case the attached resource does not support reloading.
-
reload
Reloads theImmutableResourcePropertiesfrom the resource to which theImmutableResourcePropertiesare attached to (such as aFileas ofImmutableResourceProperties.MutableResoureProperties.loadFrom(File)orImmutableResourceProperties.MutableResoureProperties.saveTo(File)). In case the resource (such as anInputStream) does not support reloading, then anIllegalStateExceptionis thrown. ImmutableProperties existing in the attached resource as well in theImmutablePropertiesitself are replaced. When "orphan removal" is set tofalse, then properties existing in the attached resource but not(!) in theImmutablePropertiesitself are not(!) removed. When "orphan removal" is set totrue, then properties existing in the attached resource but not(!) in theImmutablePropertiesitself are(!) removed.- Parameters:
aReloadMode- when set toReloadMode.ORPHAN_REMOVAL, then properties existing in the attached resource but not(!) in theImmutablePropertiesitself are(!) removed. Else properties not existing in the attached resource are kept.- Returns:
- The
ImmutablePropertiesas loaded from the resource and applied to this instance. - Throws:
IOException- thrown in case accessing the resource encountered an I/O problem.ParseException- Signals that an error has been reached unexpectedly while parsing the data to be loaded.IllegalStateException- in case the attached resource does not support reloading.
-
toSerialized
Produces the external representation of the properties as of the serialized format supported by the implementing class.- Returns:
- The external (serialized) representation of the properties.
-
toSerialized
Produces the external representation of the properties as of the serialized format supported by the implementing class.- Parameters:
aOptions- The document options with a description or the path delimiter to be used when writing out the properties to the destination (in case the the serialized format supports / requires the such).- Returns:
- The external (serialized) representation of the properties.
-