Beispiel #1
0
 /// <summary>
 /// </summary>
 /// <param name="value"></param>
 /// <remarks>
 /// associationName = schemaQualifiedName
 /// </remarks>
 public static bool IsAssociationName(string value)
 {
     return(StringValidator.IsElementName(value));
 }
Beispiel #2
0
 public static bool IsSpecialName(string name)
 {
     return(name.StartsWith("__") && StringValidator.IsIdentifier(name.Substring(2)));
 }
Beispiel #3
0
 /// <summary>
 /// </summary>
 /// <param name="value"></param>
 /// <remarks>
 /// className = elementName
 /// </remarks>
 public static bool IsClassName(string value)
 {
     return(StringValidator.IsElementName(value));
 }
Beispiel #4
0
 public static bool IsNextSchemaChar(char value)
 {
     return(StringValidator.IsFirstSchemaChar(value) ||
            StringValidator.IsDecimalDigit(value));
 }
Beispiel #5
0
 public static bool IsAliasIdentifier(string value)
 {
     return(!string.IsNullOrEmpty(value) &&
            (value.First() == '$') &&
            StringValidator.IsIdentifier(value.Substring(1)));
 }
Beispiel #6
0
 public static bool IsSchemaName(string value)
 {
     return(!string.IsNullOrEmpty(value) &&
            StringValidator.IsFirstSchemaChar(value[0]) &&
            value.Skip(1).All(StringValidator.IsNextSchemaChar));
 }
Beispiel #7
0
 public static bool IsFirstSchemaChar(char value)
 {
     return(StringValidator.IsUpperAlpha(value) ||
            StringValidator.IsLowerAlpha(value));
 }
Beispiel #8
0
 public static bool IsElementName(string value)
 {
     return(StringValidator.IsLocalName(value) ||
            StringValidator.IsSchemaQualifiedName(value));
 }
Beispiel #9
0
 public static bool IsLocalName(string value)
 {
     return(StringValidator.IsIdentifier(value));
 }
Beispiel #10
0
 public static bool IsNextIdentifierChar(char value)
 {
     return(StringValidator.IsFirstIdentifierChar(value) ||
            StringValidator.IsDecimalDigit(value));
 }
Beispiel #11
0
 public static bool IsFirstIdentifierChar(char value)
 {
     return(StringValidator.IsUpperAlpha(value) ||
            StringValidator.IsLowerAlpha(value) ||
            StringValidator.IsUnderscore(value));
 }
Beispiel #12
0
 public static bool IsIdentifier(string value)
 {
     return(!string.IsNullOrEmpty(value) &&
            StringValidator.IsFirstIdentifierChar(value.First()) &&
            value.Skip(1).All(StringValidator.IsNextIdentifierChar));
 }
Beispiel #13
0
        // realValue = ["+" / "-"] * decimalDigit "." 1*decimalDigit
        //             [ ("e" / "E") [ "+" / "-" ] 1*decimalDigit ]

        #region decimalDigit = "0" / positiveDecimalDigit

        public static bool IsDecimalDigit(char value)
        {
            return((value == '0') || StringValidator.IsPositiveDecimalDigit(value));
        }
Beispiel #14
0
 public static bool IsHexDigit(char value)
 {
     return(StringValidator.IsDecimalDigit(value) ||
            ((value >= 'a') && (value <= 'f')) ||
            ((value >= 'A') && (value <= 'F')));
 }