49#ifndef DOXYGEN_SHOULD_SKIP_THIS
56 template <
typename VAL >
62 template <
typename VAL >
67 template <
typename VAL >
72 template <
typename T >
76 for (
const auto iter = h.begin(); iter != h.end(); ++iter) {
77 NodeId new_one = iter.key();
80 GUM_ERROR(DuplicateElement, new_one <<
" already exists in the graph")
Generic doubly linked lists.
Size size() const
alias for sizeNodes
virtual void clear()
alias for clearNodes
NodeProperty< VAL > nodesPropertyFromFunction(VAL(*f)(const NodeId &), Size size=0) const
a method to create a HashTable with key:NodeId and value:VAL
NodeSet asNodeSet() const
returns a copy of the set of nodes represented by the NodeGraphPart
NodeProperty< VAL > nodesPropertyFromVal(const VAL &a, Size size=0) const
a method to create a hashMap with key:NodeId and value:VAL
List< VAL > listMapNodes(VAL(*f)(const NodeId &)) const
a method to create a list of VAL from a set of nodes (using for every nodee, say x,...
void populateNodesFromProperty(const NodeProperty< T > &h)
populateNodesFromProperty clears *this and fills it with the keys of "h"
bool existsNode(const NodeId id) const
returns true iff the NodeGraphPart contains the given nodeId
virtual void addNodeWithId(const NodeId id)
try to insert a node with the given id
List< NewKey > listMap(NewKey(*f)(const Key &)) const
A method to create a List of NewKey from the set.
HashTable< Key, NewKey > hashMap(NewKey(*f)(const Key &), Size capacity=0) const
Creates a hashtable of NewKey from the set.
#define GUM_ERROR(type, msg)
std::size_t Size
In aGrUM, hashed values are unsigned long int.
Size NodeId
Type for node ids.
HashTable< NodeId, VAL > NodeProperty
Property on graph elements.
gum is the global namespace for all aGrUM entities
Base node set class for graphs.