IsValid() public static method

public static IsValid ( byte nameType ) : bool
nameType byte
return bool
 private static byte[] CheckNameType(byte[] nameTypesSeen, byte nameType)
 {
     if (NameType.IsValid(nameType) && !Arrays.Contains(nameTypesSeen, nameType))
     {
         return(Arrays.Append(nameTypesSeen, nameType));
     }
     return(null);
 }
        private static byte[] CheckNameType(byte[] nameTypesSeen, byte nameType)
        {
            /*
             * RFC 6066 3. The ServerNameList MUST NOT contain more than one name of the same
             * name_type.
             */
            if (!NameType.IsValid(nameType) || Arrays.Contains(nameTypesSeen, nameType))
            {
                return(null);
            }

            return(Arrays.Append(nameTypesSeen, nameType));
        }