コード例 #1
0
        private DrVertexSet CreateVertexSet(DrGraph graph, DrVertex prototype, int copies)
        {
            DrVertexSet result = new DrVertexSet();

            for (int i = 0; i < copies; i++)
            {
                DrVertex v = prototype.MakeCopy(i);
                result.Add(v);
            }

            return(result);
        }
コード例 #2
0
        private DrVertexSet CreateVertexSet(DrGraph graph, DrInputStreamManager inputStream)
        {
            DrVertexSet result = new DrVertexSet();

            List <DrStorageVertex> vertices = inputStream.GetVertices();

            for (int i = 0; i < vertices.Count; i++)
            {
                DrVertex v = vertices[i];
                result.Add(v);
            }

            return(result);
        }
コード例 #3
0
        private DrVertexSet CreateVertexSet(DrGraph graph, DrOutputStreamManager outputStream, int parts)
        {
            DrVertexSet result = new DrVertexSet();

            outputStream.SetNumberOfParts(parts);

            List <DrOutputVertex> vertices = outputStream.GetVertices();

            for (int i = 0; i < vertices.Count; i++)
            {
                DrVertex v = vertices[i];
                result.Add(v);
            }

            return(result);
        }