Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::CVRPToursParser Class Referencefinal

Class parsing tours (solution) data in CVRPlib format. More...

#include <tsplib_parser.h>

Public Member Functions

 CVRPToursParser ()
 
bool LoadFile (const std::string &file_name)
 Loads and parses a given tours file.
 
const std::vector< std::vector< int > > & tours () const
 Returns a vector corresponding to the sequence of nodes of tours.
 
int64_t cost () const
 

Detailed Description

Class parsing tours (solution) data in CVRPlib format.

Definition at line 235 of file tsplib_parser.h.

Constructor & Destructor Documentation

◆ CVRPToursParser()

operations_research::CVRPToursParser::CVRPToursParser ( )

Definition at line 817 of file tsplib_parser.cc.

Member Function Documentation

◆ cost()

int64_t operations_research::CVRPToursParser::cost ( ) const
inline

Definition at line 242 of file tsplib_parser.h.

◆ LoadFile()

bool operations_research::CVRPToursParser::LoadFile ( const std::string & file_name)

Loads and parses a given tours file.

Todo
(user): Return false when issues were encountered while parsing the file.

Definition at line 821 of file tsplib_parser.cc.

◆ tours()

const std::vector< std::vector< int > > & operations_research::CVRPToursParser::tours ( ) const
inline

Returns a vector corresponding to the sequence of nodes of tours.

Definition at line 241 of file tsplib_parser.h.


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