FRAMES NO FRAMES

Class IlcTransitionTable

Definition file: ilsched/trancost.h
Include file: <ilsched/ilsched.h>

An instance of IlcTransitionTable is a square table of non-negative integers that defines the data for instances of IlcTransitionCostObject or IlcTransitionTimeObject.

The transition type of an instance of IlcActivity is used as the index of a table to calculate the transition cost or time. You can create an instance of IlcTransitionCostObject by calling the function IlcMakeTransitionCost. You can create an instance of IlcTransitionTimeObject by calling the function IlcMakeTransitionTime.

The table must be filled with non-negative integers. By default, it is initially filled with zeros. The table may or may not be symmetric, that is, the transition cost may or may not be different if an activity follows or precedes another one. If a table is declared as symmetric, the Scheduler Engine allocates only the required triangular half of the table and only that half needs to be filled. The index of the line of the table is the transition type of the preceding activity. The index of the column of the table is the transition type of the following activity.

Once the transition table has been associated with a transition time or a transition cost, the table is considered as frozen; that is, it cannot be modified any more with the member function IlcTransitionTable::setValue.

For more information, see Transition Time in Scheduler Engine, Disjunctive Constraint, Transition Cost (Setup and Teardown Costs) In Scheduler Engine, and Sequence Constraint.

See Also:

Constructor Summary
public IlcTransitionTable()
public IlcTransitionTable(IlcTransitionTableI * impl)
public IlcTransitionTable(IlcSchedule schedule, IlcInt size, IlcBool isSymmetric=IlcTrue)
public IlcTransitionTable(IlcSchedule schedule, IlcInt size, IlcInt ** _table)
Method Summary
public IlcTransitionTableI *getImpl() const
public const char *getName() const
public IlcAnygetObject() const
public IlcSchedulegetSchedule() const
public IlcIntgetSize() const
public IloSolvergetSolver() const
public IloSolverI *getSolverI() const
public IlcIntgetValue(IlcInt line, IlcInt column) const
public IlcBooloperator!=(const IlcTransitionTable & table) const
public voidoperator=(const IlcTransitionTable & h)
public IlcBooloperator==(const IlcTransitionTable & table) const
public voidsetName(const char * name) const
public voidsetObject(IlcAny object) const
public voidsetValue(IlcInt line, IlcInt column, IlcInt value)
Constructor Detail

IlcTransitionTable

public IlcTransitionTable()
This constructor creates an empty handle. You must initialize it before you use it.

IlcTransitionTable

public IlcTransitionTable(IlcTransitionTableI * impl)
This constructor creates a handle object from a pointer to an implementation object.

IlcTransitionTable

public IlcTransitionTable(IlcSchedule schedule, IlcInt size, IlcBool isSymmetric=IlcTrue)

This constructor creates a new instance of IlcTransitionTable. The size argument, which must be a strictly non-negative integer, gives the number of lines and columns of the transition table. The table is initially filled with zeroes. The Boolean argument isSymmetric expresses the fact that the table is symmetric. If isSymmetric is true, only half of the table needs to be defined.


IlcTransitionTable

public IlcTransitionTable(IlcSchedule schedule, IlcInt size, IlcInt ** _table)

This constructor creates a new instance of IlcTransitionTable. The size argument, which must be a strictly non-negative integer, gives the number of lines and columns of the transition table. The table is filled with the contents of the _table argument. The _table argument must fit size and be filled with non-negative integers.


Method Detail

getImpl

public IlcTransitionTableI * getImpl() const
This constructor creates an object by copying another one. This constructor creates an object by copying another one. This member function returns a pointer to the implementation object of the invoking handle.

getName

public const char * getName() const
This member function returns the name of the invoking object.

getObject

public IlcAny getObject() const
This member function returns a pointer to the external object associated with the invoking object, if there is such an association. It returns 0 (zero) otherwise.

getSchedule

public IlcSchedule getSchedule() const

This member function returns the schedule to which the invoking transition table belongs. Each transition table belongs to a unique schedule, an instance of IlcSchedule.


getSize

public IlcInt getSize() const

This member function returns the size of the invoking transition table.


getSolver

public IloSolver getSolver() const

This member function returns an instance of IloSolver associated with the invoking object.


getSolverI

public IloSolverI * getSolverI() const

This member function returns a pointer to the implementation object of the solver where the invoking object was extracted.


getValue

public IlcInt getValue(IlcInt line, IlcInt column) const

This member function returns the positive integer of the invoking transition table for the line line and for the column column. The arguments line and column must be non-negative integers strictly smaller than the size of the table. The argument line is the transition type of the preceding activity. The argument column is the transition type of the following activity.


operator!=

public IlcBool operator!=(const IlcTransitionTable & table) const

This operator returns IlcTrue if and only if table does not refer to the same implementation object as the invoking transition table.


operator=

public void operator=(const IlcTransitionTable & h)
This operator assigns an address to the handle pointer of the invoking object. That address is the location of the implementation object of the provided argument.

operator==

public IlcBool operator==(const IlcTransitionTable & table) const

This operator returns IlcTrue if and only if table refers to the same implementation object as the invoking transition table.


setName

public void setName(const char * name) const
This member function sets the name of the invoking object to a copy of name. This assignment is a reversible action.

setObject

public void setObject(IlcAny object) const
This member function establishes a link between the invoking object and an external object of which the invoking object might be a data member.

setValue

public void setValue(IlcInt line, IlcInt column, IlcInt value)

This member function sets the argument value as the value of the invoking transition table for the arguments line and column. The arguments line and column must be non-negative integers, strictly smaller than the size of the table. The argument value must be a non-negative integer. The argument line is the transition type of the preceding activity. The argument column is the transition type of the following activity.