类 RegistryEntry

java.lang.Object
pkg.exoad.poprock.core.registry.RegistryEntry
所有已实现的接口:
Serializable
直接已知子类:
DescriptiveRegistryEntry

public abstract class RegistryEntry extends Object implements Serializable
Base class for a registry entry which describes a certain data type held in the registry. By default it holds some very routinely used properties of an entry, but must be overriden if you want the correct functionalities.
作者:
Jack Meng
另请参阅:
  • 字段详细资料

    • currentValue

      protected Object currentValue
  • 构造器详细资料

    • RegistryEntry

      public RegistryEntry()
  • 方法详细资料

    • check

      public <T> boolean check(T r)
      Most likely should be overriden as the default implement just returns true no matter what happens! public
      类型参数:
      T - Object type
      参数:
      r - The value to check against
      返回:
      true or false if the provided value is valid for this entry
    • getCurrentValue

      public Object getCurrentValue()
      Retrieves the current value held by this current registry entry.

      This most likely does not have to be overriden!

      返回:
      The current value held
      另请参阅:
    • setCurrentValue

      public <T> void setCurrentValue(T r)
      Most likely should be overriden as the default implementation does not use check(Object)
      类型参数:
      T - Object type
      参数:
      r - The value to set to
      另请参阅:
    • defaultValue

      public Optional<?> defaultValue()
      Returns the default value held by this entry. This can be nullable
      返回:
      The default value wrapped in an Optional
    • getCanonicalName

      public abstract String getCanonicalName()