Azavea.Open.DAO.SQL.SqlDaDdlLayer.DeleteStoreRoom C# (CSharp) Method

DeleteStoreRoom() public method

Deletes the store room specified in the connection descriptor. If this data source doesn't use a store room, this method should be a no-op. If this data source DOES use store rooms, but support for adding them is not implemented yet, this should throw a NotImplementedException. Store room typically corresponds to "table". If there is no store room with the given name, this should be a no-op.
public DeleteStoreRoom ( ClassMapping mapping ) : void
mapping ClassMapping ClassMapping for the data that was stored in this room.
return void
        public virtual void DeleteStoreRoom(ClassMapping mapping)
        {
            if (!StoreRoomMissing(mapping))
            {
                SqlConnectionUtilities.XSafeCommand(_connDesc, "DROP TABLE " + mapping.Table, null);
            }
            foreach (string sequence in mapping.IdSequencesByDataCol.Values)
            {
                if (sequence != null)
                {
                    DeleteSequence(sequence);
                }
            }
        }