public override object Clone() { SQLiteObjectName objectName = null; if (_objectName != null) { objectName = (SQLiteObjectName)_objectName.Clone(); } SQLiteDdlStatement res = new SQLiteDdlStatement(); res._objectName = objectName; return(res); }
public override bool Equals(object obj) { if (obj == null) { return(false); } SQLiteDdlStatement dst = obj as SQLiteDdlStatement; if (dst == null) { return(false); } return(RefCompare.Compare(_objectName, dst._objectName)); }
public void AddStatement(SQLiteDdlStatement stmt) { if (stmt is SQLiteCreateTableStatement) { Tables.Add(stmt.ObjectName, (SQLiteCreateTableStatement)stmt); } else if (stmt is SQLiteCreateIndexStatement) { Indexes.Add(stmt.ObjectName, (SQLiteCreateIndexStatement)stmt); } else if (stmt is SQLiteCreateViewStatement) { Views.Add(stmt.ObjectName, (SQLiteCreateViewStatement)stmt); } else if (stmt is SQLiteCreateTriggerStatement) { Triggers.Add(stmt.ObjectName, (SQLiteCreateTriggerStatement)stmt); } else { throw new ArgumentException("Illegal statement type"); } }