HexColorRule

public class HexColorRule : RegexRule

HexColorRule is a subclass of RegexRule. It is used to verify whether a field is a hexadecimal color.

  • Initializes a HexaColorRule object to verify that field has text in hexadecimal color format.

    Declaration

    Swift

    public init(message: String = "is not a valid hex color.")

    Parameters

    message

    String of error message.

    Return Value

    An initialized object.