Record Class ModJavadocProcessor.Descriptor

java.lang.Object
java.lang.Record
net.fabricmc.loom.configuration.processors.ModJavadocProcessor.Descriptor
Record Components:
name - processor 名称
All Implemented Interfaces:
Serializable, MinecraftJarProcessor.ProcessorDescriptor<ModJavadocProcessor>
Enclosing class:
ModJavadocProcessor

public static record ModJavadocProcessor.Descriptor(String name) extends Record implements MinecraftJarProcessor.ProcessorDescriptor<ModJavadocProcessor>
用于在执行期重建 ModJavadocProcessor 的描述符.

本 processor 只在 processMappings 中生效,重建时除名称外不需要其他输入。

See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates an instance of a Descriptor record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    createProcessor(org.gradle.api.model.ObjectFactory objectFactory)
    使用给定的 ObjectFactory 重建 processor 实例.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Returns the value of the name record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Descriptor

      public Descriptor(String name)
      Creates an instance of a Descriptor record class.
      Parameters:
      name - the value for the name record component
  • Method Details

    • createProcessor

      public ModJavadocProcessor createProcessor(org.gradle.api.model.ObjectFactory objectFactory)
      Description copied from interface: MinecraftJarProcessor.ProcessorDescriptor
      使用给定的 ObjectFactory 重建 processor 实例.
      Specified by:
      createProcessor in interface MinecraftJarProcessor.ProcessorDescriptor<ModJavadocProcessor>
      Parameters:
      objectFactory - 用于实例化带 @Inject 构造函数的 processor,可安全地在执行期使用
      Returns:
      重建出的 processor 实例
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component