Class ConfigNodeImpl

java.lang.Object
net.ixdarklord.coolcatcore.internal.config.ConfigNodeImpl
All Implemented Interfaces:
ConfigNode
Direct Known Subclasses:
ConfigGroupImpl, ConfigValueImpl

public abstract class ConfigNodeImpl extends Object implements ConfigNode
  • Constructor Details

  • Method Details

    • key

      public String key()
      Description copied from interface: ConfigNode
      The node's key in its group, as written to the file.
      Specified by:
      key in interface ConfigNode
    • path

      public String path()
      Description copied from interface: ConfigNode
      The dotted path from the root ("rendering.particles.enabled"); empty for the root.
      Specified by:
      path in interface ConfigNode
    • config

      public ConfigImpl config()
      Specified by:
      config in interface ConfigNode
    • configOrNull

      @Nullable public @Nullable ConfigImpl configOrNull()
      The config, or null before the builder finished.
    • parent

      @Nullable public @Nullable ConfigGroupImpl parent()
      Description copied from interface: ConfigNode
      The group holding this node; null for the root.
      Specified by:
      parent in interface ConfigNode
    • comment

      public List<String> comment()
      Description copied from interface: ConfigNode
      The comment lines written above the node in the file, and shown in the config screen's tooltips.
      Specified by:
      comment in interface ConfigNode
    • translationKey

      public String translationKey()
      Description copied from interface: ConfigNode
      The key of the node's name: config.<modid>.<config>.<path>, unless the builder set another. The tooltip uses the same key with .tooltip appended, falling back to the comment.
      Specified by:
      translationKey in interface ConfigNode
    • displayName

      public net.minecraft.network.chat.Component displayName()
      Description copied from interface: ConfigNode
      The translated name, or a readable form of the key when there's no translation.
      Specified by:
      displayName in interface ConfigNode
    • isHidden

      public boolean isHidden()
      Description copied from interface: ConfigNode
      Hidden nodes are kept in the file but not shown in the config screen.
      Specified by:
      isHidden in interface ConfigNode
    • prettify

      public static String prettify(String key)
      maxCount, max_count and max-count all read "Max Count".