Analyzer.OverallReciprocationCalculator.CountEdges C# (CSharp) Method

CountEdges() protected method

protected CountEdges ( IGraph oGraph, HashSet &oVertexIDPairsOrdered, HashSet &oVertexIDPairsUnordered ) : void
oGraph IGraph
oVertexIDPairsOrdered HashSet
oVertexIDPairsUnordered HashSet
return void
        CountEdges
        (
            IGraph oGraph,
            out HashSet<Int64> oVertexIDPairsOrdered,
            out HashSet<Int64> oVertexIDPairsUnordered
        )
        {
            Debug.Assert(oGraph != null);
            Debug.Assert(oGraph.Directedness == GraphDirectedness.Directed);
           

            oVertexIDPairsOrdered = new HashSet<Int64>();
            oVertexIDPairsUnordered = new HashSet<Int64>();

            foreach (IEdge oEdge in oGraph.Edges)
            {
                if (!oEdge.IsSelfLoop)
                {
                    Int32 iVertex1ID = oEdge.Vertex1.ID;
                    Int32 iVertex2ID = oEdge.Vertex2.ID;

                    oVertexIDPairsOrdered.Add(CollectionUtil.GetDictionaryKey(
                        iVertex1ID, iVertex2ID, true));

                    oVertexIDPairsUnordered.Add(CollectionUtil.GetDictionaryKey(
                        iVertex1ID, iVertex2ID, false));
                }
            }
        }