Class SourcedSection
java.lang.Object
cc.carm.lib.configuration.source.section.AbstractMapSection<SourcedSection>
cc.carm.lib.configuration.source.section.SourcedSection
- All Implemented Interfaces:
ConfigureSection
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final @NotNull ConfigureSource<? extends SourcedSection, ?, ?> Fields inherited from class cc.carm.lib.configuration.source.section.AbstractMapSection
data, parent, path -
Constructor Summary
ConstructorsConstructorDescriptionSourcedSection(@NotNull ConfigureSource<? extends SourcedSection, ?, ?> source, @NotNull Map<?, ?> raw, @Nullable SourcedSection parent, @NotNull String path) -
Method Summary
Modifier and TypeMethodDescription@NotNull SourcedSectioncreateSection(@NotNull String path, @NotNull Map<?, ?> data) Creates a newConfigureSectionwith specified values.charGet the path separator for the section.static @NotNull SourcedSectionroot(@NotNull ConfigureSource<? extends SourcedSection, ?, ?> source) static @NotNull SourcedSectionroot(@NotNull ConfigureSource<? extends SourcedSection, ?, ?> source, @Nullable Map<?, ?> raw) @NotNull SourcedSectionself()@NotNull ConfigureSource<? extends SourcedSection, ?, ?> source()Methods inherited from class cc.carm.lib.configuration.source.section.AbstractMapSection
asMap, contains, data, get, getKeys, getValues, isEmpty, mappingKeys, mappingValues, migrate, parent, path, remove, set, sizeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface cc.carm.lib.configuration.source.section.ConfigureSection
childPath, computeSection, computeSection, computeSection, computeSection, containsValue, createSection, createSection, createSection, forEach, fullPath, get, get, get, get, getBoolean, getBoolean, getByte, getByte, getByteList, getChar, getChar, getCharList, getCollection, getDouble, getDouble, getDoubleList, getFloat, getFloat, getFloatList, getInt, getInt, getIntegerList, getList, getList, getLong, getLong, getLongList, getSection, getSectionList, getShort, getShort, getString, getString, getStringList, isBoolean, isByte, isChar, isDouble, isFloat, isInt, isList, isLong, isRoot, isSection, isShort, isString, isType, keys, stream, stream, stream, values
-
Field Details
-
source
-
-
Constructor Details
-
SourcedSection
public SourcedSection(@NotNull @NotNull ConfigureSource<? extends SourcedSection, ?, ?> source, @NotNull @NotNull Map<?, ?> raw, @Nullable @Nullable SourcedSection parent, @NotNull @NotNull String path)
-
-
Method Details
-
root
@NotNull public static @NotNull SourcedSection root(@NotNull @NotNull ConfigureSource<? extends SourcedSection, ?, ?> source) -
root
@NotNull public static @NotNull SourcedSection root(@NotNull @NotNull ConfigureSource<? extends SourcedSection, ?, ?> source, @Nullable @Nullable Map<?, ?> raw) -
source
-
pathSeparator
public char pathSeparator()Description copied from interface:ConfigureSectionGet the path separator for the section.- Returns:
- The path separator
-
self
- Specified by:
selfin classAbstractMapSection<SourcedSection>
-
createSection
@NotNull public @NotNull SourcedSection createSection(@NotNull @NotNull String path, @NotNull @NotNull Map<?, ?> data) Description copied from interface:ConfigureSectionCreates a newConfigureSectionwith specified values.The
ConfigureSection.parent()of the new section will be this section.This section will not be saved until
ConfigureSection.set(String, Object)is called.If you want to create and use a section and set it to this section, use
ConfigureSection.computeSection(String).- Specified by:
createSectionin interfaceConfigureSection- Specified by:
createSectionin classAbstractMapSection<SourcedSection>- Parameters:
data- The data to be used to create section.- Returns:
- Newly created section
-