public bool ValidateDr(string oriRelayCellName, DataRow dr, List<string> excludeCellName) { this.m_OldName = oriRelayCellName; short relayCellId = this.GetRelayCellId(oriRelayCellName); string str = dr["Name"].ToString(); IExtractor ex = new DataRowExtractor(dr); this.m_RelayCellDesc = new RelayCellDesc(this.m_Model, new RelayCell(), excludeCellName); bool flag = this.Validate(ref this.m_Info, this.m_RelayCellDesc, ex, relayCellId); this.m_SectorValidator.CellName = str; return flag; }
public bool ValidateObj(string oriRelayCellName, RelayCell relayCell, List<string> excludeRelayCellName) { this.m_OldName = oriRelayCellName; short relayCellId = this.GetRelayCellId(oriRelayCellName); string name = relayCell.Name; short validatedID = 0; IExtractor ex = new RelayCellObjExtractor(relayCell); this.m_RelayCellDesc = new RelayCellDesc(this.m_Model, new RelayCell(), excludeRelayCellName); bool flag = this.Validate(ref this.m_Info, this.m_RelayCellDesc, ex, relayCellId); this.m_SectorValidator.CellName = name; flag = flag && this.m_SectorValidator.ValidateObjectWithOutCell(oriRelayCellName, this.GetSectorConfig(relayCell)); relayCell.CopyFrom(this.m_RelayCellDesc.GetModel()); return flag; }