public static bool HasPrefix(string text, Prefix prefix) { return(Regex.IsMatch(text, prefix.Condition)); }
public bool Equals(Prefix other) { return(string.Equals(_prefix, other._prefix) && string.Equals(_condition, other._condition)); }
internal Prefix GetPrefix(string text) { return(DefaultPrefixes.FirstOrDefault(prefix => Prefix.HasPrefix(text, prefix))); }