Example #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);
 }
Example #2
0
 static Exception ParseError(TokenPosition pos, string format, params object[] args)
 {
     return(ParseError(pos.Sequence, format, args));
 }
Example #3
0
 public static Exception TokenExpected(TokenPosition errorPos, TokenId id)
 {
     return(new EntitySqlException(() => Res.TokenExpected, errorPos, id));
 }
Example #4
0
 public static Exception ArgumentTypesAreIncompatible(TokenPosition errorPos, Type type1, Type type2)
 {
     return(new EntitySqlException(() => Res.ArgumentTypesAreIncompatible, errorPos, type1.Name, type2.Name));
 }
Example #5
0
 public static Exception UnterminatedDateTimeLiteral(TokenPosition pos)
 {
     return(new EntitySqlException(() => Res.UnterminatedStringLiteral, pos));
 }
Example #6
0
 public static Exception UnterminatedBinaryLiteral(TokenPosition pos)
 {
     return(new EntitySqlException(() => Res.UnterminatedBinaryLiteral, pos));
 }
Example #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));
 }
Example #8
0
 public static EntitySqlException InvalidGroupIdentifierReference(TokenPosition errorPos, string identifier)
 {
     return(new EntitySqlException(() => Res.InvalidGroupIdentifierReference, errorPos, identifier));
 }
Example #9
0
 public void SetValues(TokenId identity, string text, TokenPosition pos)
 {
     this.Identity = identity;
     this.Text     = text;
     this.Position = pos;
 }