/// <summary> /// Initializes a new instance of the <see cref="Base"/> class. /// </summary> public Base() { m_Connection = new ConnectionAdapter(); m_TableCont = new TableContainer(this); m_ViewCont = new ViewContainer(this); m_ProcedureCont = new ProcedureContainer(this); m_FunctionCont = new FunctionContainer(this); }
/// <summary> /// Qualifies this object against another one. /// </summary> /// <param name="target">The target.</param> /// <param name="dir">The direction.</param> /// <returns></returns> public Modification qualifyVersus(FunctionContainer target, Direction dir) { Qualifier = Modification.None; foreach (Function src in Functions) { // progress.Value++; bool found = false; foreach (Function tgt in target.Functions) { if (src.Name == tgt.Name && tgt.IsGhost == false) { Modification mod = src.qualifyVersus(tgt, dir); if (Qualifier == Modification.None && mod != Modification.None) { Qualifier = Modification.Modified; } src.Twin = tgt; found = true; break; } } if (found == false) { if (dir == Direction.Out) { src.Qualifier = Modification.Deleted; } else { src.Qualifier = Modification.Created; } if (src.Twin == null) { target.Functions.Add(new Function(src)); } Qualifier = Modification.Modified; } else { } } return(Qualifier); }