Пример #1
0
 public EntitySqlException(Expression <Func <string> > msgExpr, TokenPosition pos, params object[] args)
     : this(msgExpr, args)
 {
     this.ErrorContext = string.Format(Res.ErrorContextWithoutPredicate, pos.Line + 1, pos.Column + 1);
 }
Пример #2
0
 static Exception ParseError(TokenPosition pos, string format, params object[] args)
 {
     return(ParseError(pos.Sequence, format, args));
 }
Пример #3
0
 public static Exception TokenExpected(TokenPosition errorPos, TokenId id)
 {
     return(new EntitySqlException(() => Res.TokenExpected, errorPos, id));
 }
Пример #4
0
 public static Exception ArgumentTypesAreIncompatible(TokenPosition errorPos, Type type1, Type type2)
 {
     return(new EntitySqlException(() => Res.ArgumentTypesAreIncompatible, errorPos, type1.Name, type2.Name));
 }
Пример #5
0
 public static Exception UnterminatedDateTimeLiteral(TokenPosition pos)
 {
     return(new EntitySqlException(() => Res.UnterminatedStringLiteral, pos));
 }
Пример #6
0
 public static Exception UnterminatedBinaryLiteral(TokenPosition pos)
 {
     return(new EntitySqlException(() => Res.UnterminatedBinaryLiteral, pos));
 }
Пример #7
0
 static string ErrorContext(TokenPosition pos)
 {
     return(string.Format("{0} {1} {2}, {3} {4}.", Res.LocalizedNear, Res.LocalizedLine, pos.Line + 1,
                          Res.LocalizedColumn, pos.Column + 1));
 }
Пример #8
0
 public static EntitySqlException InvalidGroupIdentifierReference(TokenPosition errorPos, string identifier)
 {
     return(new EntitySqlException(() => Res.InvalidGroupIdentifierReference, errorPos, identifier));
 }
Пример #9
0
 public void SetValues(TokenId identity, string text, TokenPosition pos)
 {
     this.Identity = identity;
     this.Text     = text;
     this.Position = pos;
 }