java.lang.Object
org.sgrewritten.stargate.api.network.portal.flag.CustomFlag
All Implemented Interfaces:
PortalFlag

public class CustomFlag extends Object implements PortalFlag
  • Method Details

    • isBehaviorFlag

      public boolean isBehaviorFlag()
      Specified by:
      isBehaviorFlag in interface PortalFlag
      Returns:

      Whether this flag relates to how a portal selects destinations

    • isInternalFlag

      public boolean isInternalFlag()
      Description copied from interface: PortalFlag
      Gets whether this flag is an internal flag

      User specifiable flags are flags like backwards or always on, which the user specifies upon creation. Internal flags are the flags that are implicitly set to some value based on the Stargate created.

      Specified by:
      isInternalFlag in interface PortalFlag
      Returns:

      True if this flag is user specifiable

    • modify

      public CustomFlag modify(boolean internalFlag, boolean behaviorFlag)
      Parameters:
      internalFlag -

      Whether this flag should be hidden for the user

      behaviorFlag -

      Whether this is a selector/behavior flag

      Returns:

      This flag

    • getCharacterRepresentation

      public char getCharacterRepresentation()
      Description copied from interface: PortalFlag
      Gets the character representing this portal flag
      Specified by:
      getCharacterRepresentation in interface PortalFlag
      Returns:

      The character representing this portal flag

    • isCustom

      public boolean isCustom()
      Specified by:
      isCustom in interface PortalFlag
      Returns:

      True if this flag is custom

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object other)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getOrCreate

      public static CustomFlag getOrCreate(char characterRepresentation)
      Get or create flags
      Parameters:
      characterRepresentation -

      The character representing the flag to get

      Returns:

      The custom flag