Enum ECSSNodeType

  • All Implemented Interfaces:
    Serializable, Comparable<ECSSNodeType>

    public enum ECSSNodeType
    extends Enum<ECSSNodeType>
    Maps the different parser tokens. This enum is only used internally. It was previously used to map between the 2.1 and the 3.0 parser constants.
    Author:
    Philip Helger
    • Method Detail

      • values

        public static ECSSNodeType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ECSSNodeType c : ECSSNodeType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ECSSNodeType valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • isNode

        public boolean isNode​(@Nonnull
                              CSSNode aParserNode,
                              @Nonnull
                              ECSSVersion eVersion)
        Check if the passed parser node is of this type.
        Parameters:
        aParserNode - The parser node to be checked.
        eVersion - The desired version.
        Returns:
        true if this is the type of the passed parser node in the given version