/// <exception cref="System.SqlSyntaxErrorException" /> public override void Process(CobarHint hint, string hintName, string sql) { Pair <int, int> pair = null; if (CurrentChar(hint, sql) == '[') { for (;;) { NextChar(hint, sql); pair = ParseDataNode(hint, sql); hint.AddDataNode(pair.Key, pair.Value); switch (CurrentChar(hint, sql)) { case ',': { continue; } case ']': { NextChar(hint, sql); return; } default: { throw new SqlSyntaxErrorException("err for dataNodeId: " + sql); } } } } pair = ParseDataNode(hint, sql); hint.AddDataNode(pair.Key, pair.Value); }
/// <exception cref="System.SqlSyntaxErrorException" /> public override void Process(CobarHint hint, string hintName, string sql) { Pair<int, int> pair = null; if (CurrentChar(hint, sql) == '[') { for (;;) { NextChar(hint, sql); pair = ParseDataNode(hint, sql); hint.AddDataNode(pair.Key, pair.Value); switch (CurrentChar(hint, sql)) { case ',': { continue; } case ']': { NextChar(hint, sql); return; } default: { throw new SqlSyntaxErrorException("err for dataNodeId: " + sql); } } } } pair = ParseDataNode(hint, sql); hint.AddDataNode(pair.Key, pair.Value); }