Record Class LaunchGroup.Entry

java.lang.Object
java.lang.Record
net.neoforged.elc.configs.LaunchGroup.Entry
Record Components:
index - The index of the entry in the Launch Group
name - The name of the launch configuration that will be executed by this entry.
enabled - If this entry is enabled, and will be executed when the Launch Group is run.
adoptIfRunning - If true, the currently executing instance will be adopted to the executed config.
mode - The execution mode. See LaunchGroup.Mode.
action - The post-launch action. See LaunchGroup.Action.
Enclosing class:
LaunchGroup

public static record LaunchGroup.Entry(int index, String name, boolean enabled, boolean adoptIfRunning, LaunchGroup.Mode mode, LaunchGroup.Action action) extends Record
Represents a single launch group entry, which are parameters on how to execute an external LaunchConfig.
  • Constructor Details

    • Entry

      public Entry(int index, String name, boolean enabled, boolean adoptIfRunning, LaunchGroup.Mode mode, LaunchGroup.Action action)
      Creates an instance of a Entry record class.
      Parameters:
      index - the value for the index record component
      name - the value for the name record component
      enabled - the value for the enabled record component
      adoptIfRunning - the value for the adoptIfRunning record component
      mode - the value for the mode record component
      action - the value for the action record component
  • Method Details

    • bakeAttributes

      public void bakeAttributes(List<EAttribute> attributes)
    • builder

      public static LaunchGroup.Entry.Builder builder(String name)
    • 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • index

      public int index()
      Returns the value of the index record component.
      Returns:
      the value of the index record component
    • name

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

      public boolean enabled()
      Returns the value of the enabled record component.
      Returns:
      the value of the enabled record component
    • adoptIfRunning

      public boolean adoptIfRunning()
      Returns the value of the adoptIfRunning record component.
      Returns:
      the value of the adoptIfRunning record component
    • mode

      public LaunchGroup.Mode mode()
      Returns the value of the mode record component.
      Returns:
      the value of the mode record component
    • action

      public LaunchGroup.Action action()
      Returns the value of the action record component.
      Returns:
      the value of the action record component