static void AddTokens(List <OmniboxToken> tokens, Match m, string groupName, OmniboxTokenType type) { var group = m.Groups[groupName]; if (group.Success) { tokens.Add(new OmniboxToken(type, group.Index, group.Value)); } }
public OmniboxToken(OmniboxTokenType type, int index, string value) { this.Type = type; this.Index = index; this.Value = value; }