Package Torello.CSS

Class CSSToken

    • Field Detail

      • serialVersionUID

        🡇     🗕  🗗  🗖
        protected static final long serialVersionUID
        This fulfils the SerialVersion UID requirement for all classes that implement Java's interface java.io.Serializable. Using the Serializable Implementation offered by java is very easy, and can make saving program state when debugging a lot easier. It can also be used in place of more complicated systems like "hibernate" to store data as well.
        See Also:
        Constant Field Values
        Code:
        Exact Field Declaration Expression:
         protected static final long serialVersionUID = 1;
        
      • str

        🡅  🡇     🗕  🗗  🗖
        public final java.lang.String str
        The "Reconstituted Character Data" (re-built from the input Code-Points array) that comprise this CSSToken.
    • Method Detail

      • subSequence

        🡅  🡇     🗕  🗗  🗖
        public final java.lang.String subSequence​(int start,
                                                  int end)
        Specified by:
        subSequence in interface java.lang.CharSequence
      • toString

        🡅  🡇     🗕  🗗  🗖
        public final java.lang.String toString()
        Specified by:
        toString in interface java.lang.CharSequence
        Overrides:
        toString in class java.lang.Object
      • compareTo

        🡅  🡇     🗕  🗗  🗖
        public final int compareTo​(java.lang.CharSequence other)
        Specified by:
        compareTo in interface java.lang.Comparable<java.lang.CharSequence>
      • isAtKeyword

        🡅  🡇     🗕  🗗  🗖
        public boolean isAtKeyword()
        Loop Optimization: This method only returns TRUE if this is an actual instance of AtKeyword.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the AtKeyword Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        AtKeyword.isAtKeyword()
      • isBadStr

        🡅  🡇     🗕  🗗  🗖
        public boolean isBadStr()
        Loop Optimization: This method only returns TRUE if this is an actual instance of BadStr.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the BadStr Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        BadStr.isBadStr()
      • isBadURL

        🡅  🡇     🗕  🗗  🗖
        public boolean isBadURL()
        Loop Optimization: This method only returns TRUE if this is an actual instance of BadURL.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the BadURL Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        BadURL.isBadURL()
      • isCDC

        🡅  🡇     🗕  🗗  🗖
        public boolean isCDC()
        Loop Optimization: This method only returns TRUE if this is an actual instance of CDC.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the CDC Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        CDC.isCDC()
      • isCDO

        🡅  🡇     🗕  🗗  🗖
        public boolean isCDO()
        Loop Optimization: This method only returns TRUE if this is an actual instance of CDO.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the CDO Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        CDO.isCDO()
      • isComment

        🡅  🡇     🗕  🗗  🗖
        public boolean isComment()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Comment.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Comment Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Comment.isComment()
      • isDelimiter

        🡅  🡇     🗕  🗗  🗖
        public boolean isDelimiter()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Delimiter.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Delimiter Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Delimiter.isDelimiter()
      • isDelimiter

        🡅  🡇     🗕  🗗  🗖
        public boolean isDelimiter​(char c)
        Checks whether 'this' instance is a Delimiter instance.
        Parameters:
        c - Any Java char.
        Returns:
        TRUE if 'this' is a delimiter containing 'c'.
      • isDimension

        🡅  🡇     🗕  🗗  🗖
        public boolean isDimension()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Dimension.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Dimension Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Dimension.isDimension()
      • isFunc

        🡅  🡇     🗕  🗗  🗖
        public boolean isFunc()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Func.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Func Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Func.isFunc()
      • isHash

        🡅  🡇     🗕  🗗  🗖
        public boolean isHash()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Hash.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Hash Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Hash.isHash()
      • isNum

        🡅  🡇     🗕  🗗  🗖
        public boolean isNum()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Num.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Num Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Num.isNum()
      • isPunct

        🡅  🡇     🗕  🗗  🗖
        public boolean isPunct()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Punct.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Punct Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Punct.isPunct()
      • isPunct

        🡅  🡇     🗕  🗗  🗖
        public final boolean isPunct​(char c)
        Checks whether 'this' instance is a punctuation character
        Parameters:
        c - Any Java char.
        Returns:
        TRUE if 'this' is a punctuation of 'c'.
      • isStr

        🡅  🡇     🗕  🗗  🗖
        public boolean isStr()
        Loop Optimization: This method only returns TRUE if this is an actual instance of Str.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the Str Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        Str.isStr()
      • isURL

        🡅  🡇     🗕  🗗  🗖
        public boolean isURL()
        Loop Optimization: This method only returns TRUE if this is an actual instance of URLToken.
        Returns:
        This method returns FALSE for all instances of CSSToken, except when 'this' instance is actually the URLToken Subclass.

        That class has overridden this method, and returns TRUE.
        See Also:
        URLToken.isURL()
      • asAtKeyword

        🡅  🡇     🗕  🗗  🗖
        public final AtKeyword asAtKeyword()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of AtKeyword Note that if this cast fails (which it must if 'this' is not actually an instance of AtKeyword), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is AtKeyword, which is the entire purpose.
      • asBadStr

        🡅  🡇     🗕  🗗  🗖
        public final BadStr asBadStr()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of BadStr Note that if this cast fails (which it must if 'this' is not actually an instance of BadStr), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is BadStr, which is the entire purpose.
      • asBadURL

        🡅  🡇     🗕  🗗  🗖
        public final BadURL asBadURL()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of BadURL Note that if this cast fails (which it must if 'this' is not actually an instance of BadURL), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is BadURL, which is the entire purpose.
      • asCDC

        🡅  🡇     🗕  🗗  🗖
        public final CDC asCDC()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of CDC Note that if this cast fails (which it must if 'this' is not actually an instance of CDC), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is CDC, which is the entire purpose.
      • asCDO

        🡅  🡇     🗕  🗗  🗖
        public final CDO asCDO()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of CDO Note that if this cast fails (which it must if 'this' is not actually an instance of CDO), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is CDO, which is the entire purpose.
      • asComment

        🡅  🡇     🗕  🗗  🗖
        public final Comment asComment()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Comment Note that if this cast fails (which it must if 'this' is not actually an instance of Comment), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Comment, which is the entire purpose.
      • asDelimiter

        🡅  🡇     🗕  🗗  🗖
        public final Delimiter asDelimiter()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Delimiter Note that if this cast fails (which it must if 'this' is not actually an instance of Delimiter), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Delimiter, which is the entire purpose.
      • asDimension

        🡅  🡇     🗕  🗗  🗖
        public final Dimension asDimension()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Dimension Note that if this cast fails (which it must if 'this' is not actually an instance of Dimension), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Dimension, which is the entire purpose.
      • asFunc

        🡅  🡇     🗕  🗗  🗖
        public final Func asFunc()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Func Note that if this cast fails (which it must if 'this' is not actually an instance of Func), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Func, which is the entire purpose.
      • asHash

        🡅  🡇     🗕  🗗  🗖
        public final Hash asHash()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Hash Note that if this cast fails (which it must if 'this' is not actually an instance of Hash), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Hash, which is the entire purpose.
      • asIdentifier

        🡅  🡇     🗕  🗗  🗖
        public final Identifier asIdentifier()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Identifier Note that if this cast fails (which it must if 'this' is not actually an instance of Identifier), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Identifier, which is the entire purpose.
      • asNum

        🡅  🡇     🗕  🗗  🗖
        public final Num asNum()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Num Note that if this cast fails (which it must if 'this' is not actually an instance of Num), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Num, which is the entire purpose.
      • asPercentage

        🡅  🡇     🗕  🗗  🗖
        public final Percentage asPercentage()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Percentage Note that if this cast fails (which it must if 'this' is not actually an instance of Percentage), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Percentage, which is the entire purpose.
      • asPunct

        🡅  🡇     🗕  🗗  🗖
        public final Punct asPunct()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Punct Note that if this cast fails (which it must if 'this' is not actually an instance of Punct), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Punct, which is the entire purpose.
      • asStr

        🡅  🡇     🗕  🗗  🗖
        public final Str asStr()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Str Note that if this cast fails (which it must if 'this' is not actually an instance of Str), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Str, which is the entire purpose.
      • asUnicodeRange

        🡅  🡇     🗕  🗗  🗖
        public final UnicodeRange asUnicodeRange()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of UnicodeRange Note that if this cast fails (which it must if 'this' is not actually an instance of UnicodeRange), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is UnicodeRange, which is the entire purpose.
      • asURL

        🡅  🡇     🗕  🗗  🗖
        public final URLToken asURL()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of URLToken Note that if this cast fails (which it must if 'this' is not actually an instance of URLToken), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is URLToken, which is the entire purpose.
      • asWhitespace

        🡅  🡇     🗕  🗗  🗖
        public final Whitespace asWhitespace()
        Loop Optimization: This method will attempt to cast 'this' instance to an instance of Whitespace Note that if this cast fails (which it must if 'this' is not actually an instance of Whitespace), then this method throws a ClassCastException.

        Note that this method is declared final, and cannot be overloaded by subclasses.
        Returns:
        If this method succeeds, it means no ClassCastException has thrown, and 'this' instance is returned. Please note that the return-type of this method is Whitespace, which is the entire purpose.
      • ifAtKeyword

        🡅  🡇     🗕  🗗  🗖
        public AtKeyword ifAtKeyword()
        Loop Optimization: When this method is invoked on an instance of sub-class AtKeyword this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of AtKeyword. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        AtKeyword.ifAtKeyword()
      • ifBadStr

        🡅  🡇     🗕  🗗  🗖
        public BadStr ifBadStr()
        Loop Optimization: When this method is invoked on an instance of sub-class BadStr this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of BadStr. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        BadStr.ifBadStr()
      • ifBadURL

        🡅  🡇     🗕  🗗  🗖
        public BadURL ifBadURL()
        Loop Optimization: When this method is invoked on an instance of sub-class BadURL this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of BadURL. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        BadURL.ifBadURL()
      • ifCDC

        🡅  🡇     🗕  🗗  🗖
        public CDC ifCDC()
        Loop Optimization: When this method is invoked on an instance of sub-class CDC this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of CDC. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        CDC.ifCDC()
      • ifCDO

        🡅  🡇     🗕  🗗  🗖
        public CDO ifCDO()
        Loop Optimization: When this method is invoked on an instance of sub-class CDO this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of CDO. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        CDO.ifCDO()
      • ifComment

        🡅  🡇     🗕  🗗  🗖
        public Comment ifComment()
        Loop Optimization: When this method is invoked on an instance of sub-class Comment this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Comment. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Comment.ifComment()
      • ifDelimiter

        🡅  🡇     🗕  🗗  🗖
        public Delimiter ifDelimiter()
        Loop Optimization: When this method is invoked on an instance of sub-class Delimiter this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Delimiter. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Delimiter.ifDelimiter()
      • ifDimension

        🡅  🡇     🗕  🗗  🗖
        public Dimension ifDimension()
        Loop Optimization: When this method is invoked on an instance of sub-class Dimension this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Dimension. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Dimension.ifDimension()
      • ifFunc

        🡅  🡇     🗕  🗗  🗖
        public Func ifFunc()
        Loop Optimization: When this method is invoked on an instance of sub-class Func this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Func. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Func.ifFunc()
      • ifHash

        🡅  🡇     🗕  🗗  🗖
        public Hash ifHash()
        Loop Optimization: When this method is invoked on an instance of sub-class Hash this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Hash. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Hash.ifHash()
      • ifNum

        🡅  🡇     🗕  🗗  🗖
        public Num ifNum()
        Loop Optimization: When this method is invoked on an instance of sub-class Num this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Num. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Num.ifNum()
      • ifPunct

        🡅  🡇     🗕  🗗  🗖
        public Punct ifPunct()
        Loop Optimization: When this method is invoked on an instance of sub-class Punct this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Punct. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Punct.ifPunct()
      • ifPunct

        🡅  🡇     🗕  🗗  🗖
        public final Punct ifPunct​(char c)
        This one actually does this cute little dance, and then and goes and makes funny faces at your mother.
        Parameters:
        c - The Punctuation Character.
        Returns:
        TRUE if and only 'this' is an instance of Punct, and one whose c field matches parameter 'c'.
        See Also:
        Punct.isPunct()
      • ifStr

        🡅  🡇     🗕  🗗  🗖
        public Str ifStr()
        Loop Optimization: When this method is invoked on an instance of sub-class Str this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Str. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Str.ifStr()
      • ifURL

        🡅  🡇     🗕  🗗  🗖
        public URLToken ifURL()
        Loop Optimization: When this method is invoked on an instance of sub-class URLToken this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of URLToken. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        URLToken.ifURL()
      • ifWhitespace

        🡅     🗕  🗗  🗖
        public Whitespace ifWhitespace()
        Loop Optimization: When this method is invoked on an instance of sub-class Whitespace this method produces 'this' instance.
        Returns:
        This method shall return null, always, except when 'this' is an actual instance of Whitespace. When so, this method simply returns 'this'. All other sub-classes of (abstract) class CSSToken inherit this method, and therefore return null.
        See Also:
        Whitespace.ifWhitespace()