public override bool Equals(object obj) { if (obj == null) { return(false); } SQLiteInsertStatement dst = obj as SQLiteInsertStatement; if (dst == null) { return(false); } if (_table != dst._table) { return(false); } if (!RefCompare.CompareMany(_prefix, dst._prefix, _select, dst._select)) { return(false); } if (!RefCompare.CompareList <string>(_columns, dst._columns)) { return(false); } if (!RefCompare.CompareList <SQLiteExpression>(_values, dst._values)) { return(false); } return(base.Equals(obj)); }
public override object Clone() { SQLiteInsertPrefix prefix = null; if (_prefix != null) { prefix = (SQLiteInsertPrefix)_prefix.Clone(); } SQLiteSelectStatement select = null; if (_select != null) { select = (SQLiteSelectStatement)_select.Clone(); } List <string> columns = null; if (_columns != null) { columns = new List <string>(); foreach (string str in _columns) { columns.Add(str); } } List <SQLiteExpression> values = null; if (_values != null) { values = new List <SQLiteExpression>(); foreach (SQLiteExpression expr in _values) { values.Add((SQLiteExpression)expr.Clone()); } // foreach } SQLiteInsertStatement res = new SQLiteInsertStatement(); res._table = _table; res._prefix = prefix; res._select = select; res._columns = columns; res._values = values; return(res); }