SNAP Library 6.0, Developer Reference  2020-12-09 16:24:20
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
TNEGraph::TNode Class Reference

#include <graph.h>

Collaboration diagram for TNEGraph::TNode:

Public Member Functions

 TNode ()
 
 TNode (const int &NId)
 
 TNode (const TNode &Node)
 
 TNode (TSIn &SIn)
 
void Save (TSOut &SOut) const
 
int GetId () const
 
int GetDeg () const
 
int GetInDeg () const
 
int GetOutDeg () const
 
int GetInEId (const int &EdgeN) const
 
int GetOutEId (const int &EdgeN) const
 
int GetNbrEId (const int &EdgeN) const
 
bool IsInEId (const int &EId) const
 
bool IsOutEId (const int &EId) const
 

Private Attributes

TInt Id
 
TIntV InEIdV
 
TIntV OutEIdV
 

Friends

class TNEGraph
 

Detailed Description

Definition at line 670 of file graph.h.

Constructor & Destructor Documentation

TNEGraph::TNode::TNode ( )
inline

Definition at line 675 of file graph.h.

675 : Id(-1), InEIdV(), OutEIdV() { }
TIntV OutEIdV
Definition: graph.h:673
TIntV InEIdV
Definition: graph.h:673
TNEGraph::TNode::TNode ( const int &  NId)
inline

Definition at line 676 of file graph.h.

676 : Id(NId), InEIdV(), OutEIdV() { }
TIntV OutEIdV
Definition: graph.h:673
TIntV InEIdV
Definition: graph.h:673
TNEGraph::TNode::TNode ( const TNode Node)
inline

Definition at line 677 of file graph.h.

677 : Id(Node.Id), InEIdV(Node.InEIdV), OutEIdV(Node.OutEIdV) { }
TIntV OutEIdV
Definition: graph.h:673
TIntV InEIdV
Definition: graph.h:673
TNEGraph::TNode::TNode ( TSIn SIn)
inline

Definition at line 678 of file graph.h.

678 : Id(SIn), InEIdV(SIn), OutEIdV(SIn) { }
TIntV OutEIdV
Definition: graph.h:673
TIntV InEIdV
Definition: graph.h:673

Member Function Documentation

int TNEGraph::TNode::GetDeg ( ) const
inline

Definition at line 681 of file graph.h.

References GetInDeg(), and GetOutDeg().

681 { return GetInDeg() + GetOutDeg(); }
int GetInDeg() const
Definition: graph.h:682
int GetOutDeg() const
Definition: graph.h:683

Here is the call graph for this function:

int TNEGraph::TNode::GetId ( ) const
inline

Definition at line 680 of file graph.h.

References Id.

Referenced by TNEGraph::DelNode(), and TNEGraph::IsOk().

680 { return Id; }

Here is the caller graph for this function:

int TNEGraph::TNode::GetInDeg ( ) const
inline

Definition at line 682 of file graph.h.

References TVec< TVal, TSizeTy >::Len().

Referenced by TNEGraph::DelNode(), GetDeg(), TNEGraph::IsEdge(), TNEGraph::TNodeI::IsInNId(), and TNEGraph::IsOk().

682 { return InEIdV.Len(); }
TSizeTy Len() const
Returns the number of elements in the vector.
Definition: ds.h:575
TIntV InEIdV
Definition: graph.h:673

Here is the call graph for this function:

Here is the caller graph for this function:

int TNEGraph::TNode::GetInEId ( const int &  EdgeN) const
inline

Definition at line 684 of file graph.h.

Referenced by TNEGraph::DelNode(), GetNbrEId(), TNEGraph::IsEdge(), TNEGraph::TNodeI::IsInNId(), and TNEGraph::IsOk().

684 { return InEIdV[EdgeN]; }
TIntV InEIdV
Definition: graph.h:673

Here is the caller graph for this function:

int TNEGraph::TNode::GetNbrEId ( const int &  EdgeN) const
inline

Definition at line 686 of file graph.h.

References GetInEId(), GetOutDeg(), and GetOutEId().

686 { return EdgeN<GetOutDeg()?GetOutEId(EdgeN):GetInEId(EdgeN-GetOutDeg()); }
int GetOutEId(const int &EdgeN) const
Definition: graph.h:685
int GetOutDeg() const
Definition: graph.h:683
int GetInEId(const int &EdgeN) const
Definition: graph.h:684

Here is the call graph for this function:

int TNEGraph::TNode::GetOutDeg ( ) const
inline

Definition at line 683 of file graph.h.

References TVec< TVal, TSizeTy >::Len().

Referenced by TNEGraph::DelNode(), GetDeg(), GetNbrEId(), TNEGraph::IsEdge(), TNEGraph::IsOk(), and TNEGraph::TNodeI::IsOutNId().

683 { return OutEIdV.Len(); }
TSizeTy Len() const
Returns the number of elements in the vector.
Definition: ds.h:575
TIntV OutEIdV
Definition: graph.h:673

Here is the call graph for this function:

Here is the caller graph for this function:

int TNEGraph::TNode::GetOutEId ( const int &  EdgeN) const
inline

Definition at line 685 of file graph.h.

Referenced by TNEGraph::DelNode(), GetNbrEId(), TNEGraph::IsEdge(), TNEGraph::IsOk(), and TNEGraph::TNodeI::IsOutNId().

685 { return OutEIdV[EdgeN]; }
TIntV OutEIdV
Definition: graph.h:673

Here is the caller graph for this function:

bool TNEGraph::TNode::IsInEId ( const int &  EId) const
inline

Definition at line 687 of file graph.h.

References TVec< TVal, TSizeTy >::SearchBin().

687 { return InEIdV.SearchBin(EId) != -1; }
TSizeTy SearchBin(const TVal &Val) const
Returns the position of an element with value Val.
Definition: ds.h:1519
TIntV InEIdV
Definition: graph.h:673

Here is the call graph for this function:

bool TNEGraph::TNode::IsOutEId ( const int &  EId) const
inline

Definition at line 688 of file graph.h.

References TVec< TVal, TSizeTy >::SearchBin().

688 { return OutEIdV.SearchBin(EId) != -1; }
TIntV OutEIdV
Definition: graph.h:673
TSizeTy SearchBin(const TVal &Val) const
Returns the position of an element with value Val.
Definition: ds.h:1519

Here is the call graph for this function:

void TNEGraph::TNode::Save ( TSOut SOut) const
inline

Definition at line 679 of file graph.h.

References TVec< TVal, TSizeTy >::Save(), and TInt::Save().

679 { Id.Save(SOut); InEIdV.Save(SOut); OutEIdV.Save(SOut); }
void Save(TSOut &SOut) const
Definition: dt.h:1153
void Save(TSOut &SOut) const
Definition: ds.h:954
TIntV OutEIdV
Definition: graph.h:673
TIntV InEIdV
Definition: graph.h:673

Here is the call graph for this function:

Friends And Related Function Documentation

friend class TNEGraph
friend

Definition at line 689 of file graph.h.

Member Data Documentation

TInt TNEGraph::TNode::Id
private

Definition at line 672 of file graph.h.

Referenced by GetId().

TIntV TNEGraph::TNode::InEIdV
private

Definition at line 673 of file graph.h.

Referenced by TNEGraph::AddEdge(), TNEGraph::Defrag(), TNEGraph::DelEdge(), and TNEGraph::IsOk().

TIntV TNEGraph::TNode::OutEIdV
private

Definition at line 673 of file graph.h.

Referenced by TNEGraph::AddEdge(), TNEGraph::Defrag(), TNEGraph::DelEdge(), and TNEGraph::IsOk().


The documentation for this class was generated from the following file: