Class HexColourValidator

java.lang.Object
com.atlassian.validation.HexColourValidator
All Implemented Interfaces:
Validator

public class HexColourValidator extends Object implements Validator
Validate a string matches what we expect for a hex representation of a colour eg. "#33445A"
Since:
v5.2
  • Constructor Details

    • HexColourValidator

      public HexColourValidator()
  • Method Details

    • validate

      public Validator.Result validate(String value)
      Description copied from interface: Validator
      Validate the given string to see if it passes and if not, why not.
      Specified by:
      validate in interface Validator
      Parameters:
      value - all validation input is a String.
      Returns:
      A result that contains access to the details of the validation outcome.