コード例 #1
0
        private void AddDependentNodes(DTreeNode<DependencyGraphData> rootNode, TypeData tData)
        {
            foreach (DependencyTypeData data in typeDependData)
            {
                if (data.TypeName.Equals(tData.ToString()))
                {
                    // add data.ImplTypeName to graph as dependency
                    rootNode.Nodes.Add(
                        GetDependencyGraphNode(new DTreeItem(data.ImplTypeName, data.SelectionType), GraphDataArrow.TO,
                                               "implements"));
                }

                if (data.ImplTypeName.Equals(tData.ToString()))
                {
                    // add data.TypeName to graph as dependent
                    rootNode.Nodes.Add(
                        GetDependencyGraphNode(new DTreeItem(data.TypeName, SelectionType.TYPE), GraphDataArrow.FROM,
                                               "implements"));
                }
            }
        }
コード例 #2
0
        private static void AddFieldNodes(DTreeNode<DependencyGraphData> rootNode, TypeData tData)
        {
            foreach (String field in tData.Fields)
            {
                rootNode.Nodes.Add(
                    GetDependencyGraphNode(new DTreeItem(field, SelectionType.FIELD), GraphDataArrow.TO, "contains"));
            }

            foreach (String props in tData.Properties)
            {
                rootNode.Nodes.Add(
                    GetDependencyGraphNode(new DTreeItem(props, SelectionType.PROPERTY), GraphDataArrow.TO, "contains"));
            }
        }