Esempio n. 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));
        }
Esempio n. 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);
Esempio n. 3
0
 /// <summary> Implements visitor pattern for ValueExpression</summary>
 public abstract void Visit(ValueExpression value);
Esempio n. 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);
        }
Esempio n. 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);
        }