The first line of the section contains the names of the maps separated with white spaces. Each next line describes an item in the itemset, and contains in the first column the label of the item and then the mapped values for each map. #include <lemon/lemon_reader.h>
Public Member Functions | |
template<typename _LabelReader > | |
EdgeMapReader (LemonReader &_reader, const Graph &_graph, const _LabelReader &_labelReader, const std::string &_name=std::string(), const DefaultSkipper &_skipper=DefaultSkipper()) | |
Constructor. | |
virtual | ~EdgeMapReader () |
Destructor. | |
template<typename Map > | |
EdgeMapReader & | readEdgeMap (std::string label, Map &map) |
template<typename ItemReader , typename Map > | |
EdgeMapReader & | readEdgeMap (std::string label, Map &map, const ItemReader &ir=ItemReader()) |
template<typename ItemReader > | |
EdgeMapReader & | skipEdgeMap (std::string label, const ItemReader &ir=ItemReader()) |
Protected Member Functions | |
virtual bool | header (const std::string &line) |
Gives back true when the SectionReader can process the section with the given header line. | |
virtual void | read (std::istream &is) |
Reader function of the section. |
EdgeMapReader | ( | LemonReader & | _reader, | |
const Graph & | _graph, | |||
const _LabelReader & | _labelReader, | |||
const std::string & | _name = std::string() , |
|||
const DefaultSkipper & | _skipper = DefaultSkipper() | |||
) | [inline] |
Constructor for EdgeMapReader. It creates the EdgeMapReader and attach it into the given LemonReader. The reader will read the section when the section_name
and the _name
are the same.
virtual ~EdgeMapReader | ( | ) | [inline, virtual] |
Destructor for EdgeMapReader.
EdgeMapReader& readEdgeMap | ( | std::string | label, | |
Map & | map | |||
) | [inline] |
Add a new edge map reader command for the reader.
EdgeMapReader& readEdgeMap | ( | std::string | label, | |
Map & | map, | |||
const ItemReader & | ir = ItemReader() | |||
) | [inline] |
Add a new edge map reader command for the reader.
EdgeMapReader& skipEdgeMap | ( | std::string | label, | |
const ItemReader & | ir = ItemReader() | |||
) | [inline] |
Add a new edge map skipper command for the reader.
virtual bool header | ( | const std::string & | line | ) | [inline, protected, virtual] |
It gives back true when the header line starts with @mapset
, and the header line's name and the mapset's name are the same.
Implements SectionReader.
virtual void read | ( | std::istream & | is | ) | [inline, protected, virtual] |
It reads the content of the section.
Implements SectionReader.