Exemplo n.º 1
0
        public DbParameter[] BuildParamters(InComparison c)
        {
            DbParameter[] results = new DbParameter[c.Parameters.Length];

            for (int i = 0; i < c.Parameters.Length; i++)
            {
                results[i] = BuildParameter(c.Parameters[i]);
            }

            return(results);
        }
Exemplo n.º 2
0
        public DbParameter[] GetParameters(IHasFilters filter)
        {
            List <DbParameter> parameters = new List <DbParameter>();

            foreach (IFilterToken token in filter.Filters)
            {
                IParameterInfo c = token as IParameterInfo;
                if (c != null)
                {
                    InComparison inC = c as InComparison;
                    if (inC != null)
                    {
                        parameters.AddRange(BuildParamters(inC));
                    }
                    else
                    {
                        parameters.Add(this.BuildParameter(c));
                    }
                }
            }

            return(parameters.ToArray());
        }