C++ Reference: class StarGraphBase

Note: This documentation is automatically generated.

Method
ArcDebugString

Return type: std::string

Arguments: const ArcIndexType arc

end_arc_index

Return type: ArcIndexType

Returns one more than the largest index of an extant direct arc. To be used as a helper when clients need to dimension or iterate over arrays of arc annotation information.

end_node_index

Return type: NodeIndexType

Returns one more than the largest index of an extant node, meaning a node that is mentioned as the head or tail of some arc in the graph. To be used as a helper when clients need to dimension or iterate over arrays of node annotation information.

IsNodeValid

Return type: bool

Arguments: NodeIndexType node

Utility function to check that a node index is within the bounds AND different from kNilNode. Returns true if node is in the range [kFirstNode .. max_num_nodes_). It is exported so that users of the DerivedGraph class can use it. To be used in a DCHECK; also used internally to validate arguments passed to our methods from clients (e.g., AddArc()).

LookUpArc

Return type: ArcIndexType

Arguments: const NodeIndexType tail, const NodeIndexType head

Returns the first arc going from tail to head, if it exists, or kNilArc if such an arc does not exist.

max_end_arc_index

Return type: ArcIndexType

Returns one more than the largest valid index of a direct arc. To be used as a helper when clients need to dimension or iterate over arrays of arc annotation information.

max_end_node_index

Return type: NodeIndexType

Returns one more than the largest valid index of a node. To be used as a helper when clients need to dimension or iterate over arrays of node annotation information.

max_num_arcs

Return type: ArcIndexType

Returns the maximum possible number of original arcs in the graph. (The ones with positive indices.)

max_num_nodes

Return type: NodeIndexType

Returns the maximum possible number of nodes in the graph.

NodeDebugString

Return type: std::string

Arguments: const NodeIndexType node

num_arcs

Return type: ArcIndexType

Returns the number of original arcs in the graph (The ones with positive indices.)

num_nodes

Return type: NodeIndexType

Returns the number of nodes in the graph.