- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# VrpSolution Class Reference

This class contains a vrp solution. More...

`#include <VrpSolution.h>`

Inheritance diagram for VrpSolution:

[legend]
Collaboration diagram for VrpSolution:

[legend]
List of all members.

## Public Member Functions
| VrpSolution ()
| Default constructor.
| VrpSolution (int s, const double *values, double objValue, VrpModel *vrp=0)
| Useful constructor.
virtual | ~VrpSolution ()
| Destructor.
void | setOpt (_node *opt)
| Set opt.
virtual void | print (std::ostream &os) const
| Print the solution.
virtual AlpsEncoded * | encode () const
| The method that encodes the solution into a encoded object.
virtual AlpsKnowledge * | decode (AlpsEncoded &encoded) const
| The method that decodes the solution from a encoded object.
## Protected Attributes
_node * | opt_

## Detailed Description

This class contains a vrp solution.

Definition at line 26 of file VrpSolution.h.

## Constructor & Destructor Documentation

VrpSolution::VrpSolution | ( |  | ) | `[inline]`

Default constructor.

Definition at line 35 of file VrpSolution.h.

Referenced by decode().

VrpSolution::VrpSolution | ( | int | s,
|  | const double * | values,
|  | double | objValue,
|  | VrpModel * | vrp = `0` |
| ) |  |  |

Useful constructor.

virtual VrpSolution::~VrpSolution | ( |  | ) | `[inline, virtual]`

Destructor.

Definition at line 42 of file VrpSolution.h.

References opt_.

## Member Function Documentation

void VrpSolution::setOpt | ( | _node * | opt | ) | `[inline]`

Set opt.

Definition at line 47 of file VrpSolution.h.

References opt_.

Referenced by decode().

virtual void VrpSolution::print | ( | std::ostream & | os | ) | const`[virtual]`

Print the solution.

Reimplemented from BlisSolution.

virtual AlpsEncoded* VrpSolution::encode | ( |  | ) | const`[inline, virtual]`

The method that encodes the solution into a encoded object.

Reimplemented from BlisSolution.

Definition at line 56 of file VrpSolution.h.

References AlpsKnowledgeTypeSolution, BcpsSolution::encodeBcps(), _NODE::next, opt_, and AlpsEncoded::writeRep().

virtual AlpsKnowledge* VrpSolution::decode | ( | AlpsEncoded & | encoded | ) | const`[inline, virtual]`

The method that decodes the solution from a encoded object.

Reimplemented from BlisSolution.

Definition at line 76 of file VrpSolution.h.

References BcpsSolution::decodeBcps(), _NODE::next, AlpsEncoded::readRep(), setOpt(), and VrpSolution().

## Member Data Documentation

_node* VrpSolution::opt_`[protected]`

Definition at line 30 of file VrpSolution.h.

Referenced by encode(), setOpt(), and ~VrpSolution().

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

- /home/coin/SVN-release/Blis-0.91.0/Blis/examples/VRP/VrpSolution.h