The abstract base class of any user-defined class that Alps has to know about in order to encode/decode. More...
#include <AlpsKnowledge.h>
Public Member Functions | |
AlpsKnowledge () | |
virtual | ~AlpsKnowledge () |
KnowledgeType | getType () |
void | setType (KnowledgeType t) |
virtual AlpsEncoded * | encode () const |
This method should encode the content of the object and return a pointer to the encoded form. More... | |
virtual AlpsReturnStatus | encode (AlpsEncoded *encoded) |
Pack into a encode object. More... | |
virtual AlpsKnowledge * | decode (AlpsEncoded &encoded) const |
This method should decode and return a pointer to a brand new object, i.e., the method must create a new object on the heap from the decoded data instead of filling up the object for which the method was invoked. More... | |
AlpsEncoded * | getEncoded () const |
Get/set encoded. More... | |
void | setEncoded (AlpsEncoded *e) |
Protected Attributes | |
KnowledgeType | type_ |
Private Member Functions | |
AlpsKnowledge (const AlpsKnowledge &) | |
AlpsKnowledge & | operator= (const AlpsKnowledge &) |
Private Attributes | |
AlpsEncoded * | encoded_ |
The encoded object in an encoded form (could be compressed!) More... | |
The abstract base class of any user-defined class that Alps has to know about in order to encode/decode.
These classes must all be registered so that the proper decode method can be called.
Definition at line 51 of file AlpsKnowledge.h.
|
private |
|
inline |
Definition at line 68 of file AlpsKnowledge.h.
|
inlinevirtual |
Definition at line 69 of file AlpsKnowledge.h.
|
private |
|
inline |
Definition at line 71 of file AlpsKnowledge.h.
|
inline |
Definition at line 72 of file AlpsKnowledge.h.
|
virtual |
This method should encode the content of the object and return a pointer to the encoded form.
NOTE: This default implementation can not be used when the memory of data members is not continously allocated, for example, some data members are pointers, STL set, map, etc.
Reimplemented in AbcModel, BlisModel, BlisModel, AlpsSubTree, VrpModel, BlisTreeNode, AbcTreeNode, BlisTreeNode, BlisPseudocost, KnapTreeNode, KnapModel, AbcSolution, BlisSolution, KnapSolution, BlisSolution, and VrpSolution.
|
inlinevirtual |
Pack into a encode object.
Reimplemented in BcpsObject, BlisVariable, BlisVariable, BlisConstraint, VrpVariable, and BlisConstraint.
Definition at line 83 of file AlpsKnowledge.h.
|
virtual |
This method should decode and return a pointer to a brand new object, i.e., the method must create a new object on the heap from the decoded data instead of filling up the object for which the method was invoked.
NOTE: This default implementation can not be used when the memory of data members is not continously allocated, for example, some data members are pointers, STL set, map, etc.
Reimplemented in BcpsObject, AlpsSubTree, BlisTreeNode, BlisTreeNode, BlisPseudocost, AbcTreeNode, KnapTreeNode, BlisVariable, BlisVariable, VrpVariable, BlisConstraint, BlisConstraint, BlisSolution, AbcSolution, KnapSolution, VrpSolution, and BlisSolution.
|
inline |
Get/set encoded.
Definition at line 98 of file AlpsKnowledge.h.
|
inline |
Definition at line 99 of file AlpsKnowledge.h.
|
private |
The encoded object in an encoded form (could be compressed!)
Definition at line 60 of file AlpsKnowledge.h.
|
protected |
Definition at line 64 of file AlpsKnowledge.h.