SNAP Library 3.0, Developer Reference  2016-07-20 17:56:49
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
TNodeEdgeNet< TNodeData, TEdgeData >::TNode Class Reference

#include <network.h>

Collaboration diagram for TNodeEdgeNet< TNodeData, TEdgeData >::TNode:

Public Member Functions

 TNode ()
 
 TNode (const int &NId)
 
 TNode (const int &NId, const TNodeData &NodeData)
 
 TNode (const TNode &Node)
 
 TNode (TSIn &SIn)
 
void Save (TSOut &SOut) const
 
bool operator< (const TNode &Node) const
 
int GetId () const
 
int GetDeg () const
 
int GetInDeg () const
 
int GetOutDeg () const
 
const TNodeData & GetDat () const
 
TNodeData & GetDat ()
 
int GetInEId (const int &NodeN) const
 
int GetOutEId (const int &NodeN) const
 
int GetNbrEId (const int &EdgeN) const
 
bool IsInEId (const int &EId) const
 
bool IsOutEId (const int &EId) const
 
bool IsNbrEId (const int &EId) const
 

Private Attributes

TInt Id
 
TIntV InEIdV
 
TIntV OutEIdV
 
TNodeData NodeDat
 

Friends

class TNodeEdgeNet< TNodeData, TEdgeData >
 

Detailed Description

template<class TNodeData, class TEdgeData>
class TNodeEdgeNet< TNodeData, TEdgeData >::TNode

Definition at line 988 of file network.h.

Constructor & Destructor Documentation

template<class TNodeData, class TEdgeData>
TNodeEdgeNet< TNodeData, TEdgeData >::TNode::TNode ( )
inline

Definition at line 994 of file network.h.

994 : Id(-1), InEIdV(), OutEIdV(), NodeDat() { }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
TNodeEdgeNet< TNodeData, TEdgeData >::TNode::TNode ( const int &  NId)
inline

Definition at line 995 of file network.h.

995 : Id(NId), InEIdV(), OutEIdV(), NodeDat() { }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
TNodeEdgeNet< TNodeData, TEdgeData >::TNode::TNode ( const int &  NId,
const TNodeData &  NodeData 
)
inline

Definition at line 996 of file network.h.

996 : Id(NId), InEIdV(), OutEIdV(), NodeDat(NodeData) { }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
TNodeEdgeNet< TNodeData, TEdgeData >::TNode::TNode ( const TNode Node)
inline

Definition at line 997 of file network.h.

997 : Id(Node.Id), InEIdV(Node.InEIdV), OutEIdV(Node.OutEIdV), NodeDat(Node.NodeDat) { }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
TNodeEdgeNet< TNodeData, TEdgeData >::TNode::TNode ( TSIn SIn)
inline

Definition at line 998 of file network.h.

998 : Id(SIn), InEIdV(SIn), OutEIdV(SIn), NodeDat(SIn) { }
TNodeData NodeDat
Definition: network.h:992

Member Function Documentation

template<class TNodeData, class TEdgeData>
const TNodeData& TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetDat ( ) const
inline

Definition at line 1005 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::NodeDat.

Referenced by TNodeEdgeNet< TNodeData, TEdgeData >::TNodeI::IsOutNId().

1005 { return NodeDat; }
TNodeData NodeDat
Definition: network.h:992

Here is the caller graph for this function:

template<class TNodeData, class TEdgeData>
TNodeData& TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetDat ( )
inline

Definition at line 1006 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::NodeDat.

1006 { return NodeDat; }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetDeg ( ) const
inline

Definition at line 1002 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetInDeg(), and TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetOutDeg().

1002 { return GetInDeg() + GetOutDeg(); }
int GetOutDeg() const
Definition: network.h:1004
int GetInDeg() const
Definition: network.h:1003

Here is the call graph for this function:

template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetId ( ) const
inline

Definition at line 1001 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::Id.

Referenced by TNodeEdgeNet< TNodeData, TEdgeData >::IsOk().

1001 { return Id; }

Here is the caller graph for this function:

template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetInDeg ( ) const
inline

Definition at line 1003 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::InEIdV, and TVec< TVal, TSizeTy >::Len().

Referenced by TNodeEdgeNet< TNodeData, TEdgeData >::DelNode(), TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetDeg(), TNodeEdgeNet< TNodeData, TEdgeData >::IsEdge(), TNodeEdgeNet< TNodeData, TEdgeData >::TNodeI::IsInNId(), and TNodeEdgeNet< TNodeData, TEdgeData >::IsOk().

1003 { return InEIdV.Len(); }
TSizeTy Len() const
Returns the number of elements in the vector.
Definition: ds.h:547

Here is the call graph for this function:

Here is the caller graph for this function:

template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetInEId ( const int &  NodeN) const
inline
template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetNbrEId ( const int &  EdgeN) const
inline

Definition at line 1009 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetInEId(), TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetOutDeg(), and TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetOutEId().

1009 { return EdgeN<GetOutDeg()?GetOutEId(EdgeN):GetInEId(EdgeN-GetOutDeg()); }
int GetOutDeg() const
Definition: network.h:1004
int GetInEId(const int &NodeN) const
Definition: network.h:1007
int GetOutEId(const int &NodeN) const
Definition: network.h:1008

Here is the call graph for this function:

template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetOutDeg ( ) const
inline
template<class TNodeData, class TEdgeData>
int TNodeEdgeNet< TNodeData, TEdgeData >::TNode::GetOutEId ( const int &  NodeN) const
inline
template<class TNodeData, class TEdgeData>
bool TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsInEId ( const int &  EId) const
inline

Definition at line 1010 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::InEIdV, and TVec< TVal, TSizeTy >::SearchBin().

Referenced by TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsNbrEId().

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

Here is the call graph for this function:

Here is the caller graph for this function:

template<class TNodeData, class TEdgeData>
bool TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsNbrEId ( const int &  EId) const
inline

Definition at line 1012 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsInEId(), and TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsOutEId().

1012 { return IsInEId(EId) || IsOutEId(EId); }
bool IsOutEId(const int &EId) const
Definition: network.h:1011
bool IsInEId(const int &EId) const
Definition: network.h:1010

Here is the call graph for this function:

template<class TNodeData, class TEdgeData>
bool TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsOutEId ( const int &  EId) const
inline

Definition at line 1011 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::OutEIdV, and TVec< TVal, TSizeTy >::SearchBin().

Referenced by TNodeEdgeNet< TNodeData, TEdgeData >::TNode::IsNbrEId().

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

Here is the call graph for this function:

Here is the caller graph for this function:

template<class TNodeData, class TEdgeData>
bool TNodeEdgeNet< TNodeData, TEdgeData >::TNode::operator< ( const TNode Node) const
inline

Definition at line 1000 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::NodeDat.

1000 { return NodeDat < Node.NodeDat; }
TNodeData NodeDat
Definition: network.h:992
template<class TNodeData, class TEdgeData>
void TNodeEdgeNet< TNodeData, TEdgeData >::TNode::Save ( TSOut SOut) const
inline

Definition at line 999 of file network.h.

References TNodeEdgeNet< TNodeData, TEdgeData >::TNode::Id, TNodeEdgeNet< TNodeData, TEdgeData >::TNode::InEIdV, TNodeEdgeNet< TNodeData, TEdgeData >::TNode::NodeDat, TNodeEdgeNet< TNodeData, TEdgeData >::TNode::OutEIdV, TVec< TVal, TSizeTy >::Save(), and TInt::Save().

999 { Id.Save(SOut); InEIdV.Save(SOut); OutEIdV.Save(SOut); NodeDat.Save(SOut); }
void Save(TSOut &SOut) const
Definition: dt.h:1060
TNodeData NodeDat
Definition: network.h:992
void Save(TSOut &SOut) const
Definition: ds.h:903

Here is the call graph for this function:

Friends And Related Function Documentation

template<class TNodeData, class TEdgeData>
friend class TNodeEdgeNet< TNodeData, TEdgeData >
friend

Definition at line 1013 of file network.h.

Member Data Documentation

template<class TNodeData, class TEdgeData>
TInt TNodeEdgeNet< TNodeData, TEdgeData >::TNode::Id
private

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