Package io.netty.util

Class Signal

  • All Implemented Interfaces:
    Constant<Signal>, java.io.Serializable, java.lang.Comparable<Signal>

    public final class Signal
    extends java.lang.Error
    implements Constant<Signal>
    A special Error which is used to signal some state or request by throwing it. Signal has an empty stack trace and has no cause to save the instantiation overhead.
    See Also:
    Serialized Form
    • Method Detail

      • valueOf

        public static Signal valueOf​(java.lang.String name)
        Returns the Signal of the specified name.
      • expect

        public void expect​(Signal signal)
        Check if the given Signal is the same as this instance. If not an IllegalStateException will be thrown.
      • initCause

        public java.lang.Throwable initCause​(java.lang.Throwable cause)
        Overrides:
        initCause in class java.lang.Throwable
      • fillInStackTrace

        public java.lang.Throwable fillInStackTrace()
        Overrides:
        fillInStackTrace in class java.lang.Throwable
      • id

        public int id()
        Description copied from interface: Constant
        Returns the unique number assigned to this Constant.
        Specified by:
        id in interface Constant<Signal>
      • name

        public java.lang.String name()
        Description copied from interface: Constant
        Returns the name of this Constant.
        Specified by:
        name in interface Constant<Signal>
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • compareTo

        public int compareTo​(Signal other)
        Specified by:
        compareTo in interface java.lang.Comparable<Signal>
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Throwable