Пример #1
0
        /// <summary>
        /// Returns true if the ValueExpression represents a primitive
        /// </summary>
        protected virtual bool HandlePrimitiveValue(ValueExpression expr)
        {
            var tv = expr.Value.GetType();

            return(DEFAULT_PRIMITIVE_TYPES.Contains(tv));
        }
Пример #2
0
 /// <summary>
 /// Override to create a parameter, assigning (and converting) value.
 /// You can throw ASTException if some unsupported value was passed-in
 /// </summary>
 protected abstract IDataParameter MakeAndAssignParameter(ValueExpression value);
Пример #3
0
 /// <summary> Implements visitor pattern for ValueExpression</summary>
 public abstract void Visit(ValueExpression value);
Пример #4
0
        /// <summary>
        /// Creates MySql specific parameter
        /// </summary>
        protected override IDataParameter MakeAndAssignParameter(ValueExpression value)
        {
            var p = new MySqlParameter($"{ParameterNamePrefix}{m_ParamCount++}", value.Value);

            return(p);
        }
Пример #5
0
        /// <summary>
        /// Creates ORA specific parameter
        /// </summary>
        protected override IDataParameter MakeAndAssignParameter(ValueExpression value)
        {
            var p = new Oracle.ManagedDataAccess.Client.OracleParameter($"{ParameterNamePrefix}{m_ParamCount++}", value.Value);

            return(p);
        }