类 RegistryEntryFactory

java.lang.Object
pkg.exoad.poprock.core.registry.RegistryEntryFactory
所有已实现的接口:
DebuggableAllRequiredNamedFieldsMixin, ICollatable<RegistryEntry>
直接已知子类:
DescriptiveRegistryEntryFactory

public sealed class RegistryEntryFactory extends Object implements ICollatable<RegistryEntry>, DebuggableAllRequiredNamedFieldsMixin permits DescriptiveRegistryEntryFactory
RegistryEntry Factory

This class helps to construct a RegistryEntry using method chaining. It provides all of the necessary fields and construction functionality to make a working Registry Entry.

To use this class, you must call make()!
作者:
Jack Meng
另请参阅:
  • 字段详细资料

  • 构造器详细资料

    • RegistryEntryFactory

      protected RegistryEntryFactory()
  • 方法详细资料

    • make

      public static RegistryEntryFactory make()
      Starts the factory of making a registry entry using method chaining
      返回:
      A new instance of the Registry Entry Factory
    • withCheck

      public RegistryEntryFactory withCheck(Functor11<Boolean,Object> check)
      Named constructor method for setting the checker function. Please note that the functionality of the checker is mainly used for custom user implemented checks. For example Integer Bound Checks, these are not handled by any registries themselves (for the most part).
      参数:
      check - The checker function
      返回:
      this
    • withCanonicalName

      public RegistryEntryFactory withCanonicalName(String name)
      Named constructor method for setting the canonical name property
      参数:
      name - The canonical name
      返回:
      this
    • withDefaultValue

      public RegistryEntryFactory withDefaultValue(Object defaultCheck)
      Named constructor method for setting the default value on false evaluation
      参数:
      defaultCheck - The default value
      返回:
      this
    • withValue

      public RegistryEntryFactory withValue(Object value)
    • collate

      public RegistryEntry collate()
      从接口复制的说明: ICollatable
      Output a different type
      指定者:
      collate 在接口中 ICollatable<RegistryEntry>
      返回:
      The produced object
    • checkTargets

      protected void checkTargets()
      Internal method used to check the most basic properties.

      This method should be called by child classes to make sure at least the base properties are met.