Aimsun Next Scripting  22
Public Member Functions | List of all members
GKODMatrixReaderODBC Class Reference
Inheritance diagram for GKODMatrixReaderODBC:
GKODMatrixReaderExternal

Public Member Functions

 GKODMatrixReaderODBC ()
 
void setDbInfo (const GKDataBaseInfo &)
 
const GKDataBaseInfogetDbInfo () const
 
bool read (GKODMatrix *)
 
bool write (GKODMatrix *)
 
void setRID (int)
 
void setTimeInt (int)
 
- Public Member Functions inherited from GKODMatrixReaderExternal
 GKODMatrixReaderExternal ()
 
void setMode (const GKODMatrix::GKODMatrixStoreId &)
 
virtual bool read (GKODMatrix *)=0
 
virtual bool write (const GKODMatrix *)=0
 

Detailed Description

This class can be used at any moment to store or restore an existing an od as long as the database connection data (db, username, password) and the GKODMatrixReaderExternal::setMode are correct.

It will read or write the following information:

CTYPE is set using the vehicle type name (GKODMatrix::getVehicle, GKVehicle::getName) as:

Example:

dbinfo.setDatabaseName( "DB_NAME" )
dbinfo.setUserName( "USER_NAME" )
dbinfo.setPassword( "PASSWORD" )
readerODBC.setDbInfo( dbinfo )
readerODBC.setMode( GKODMatrix.eEID )
readerODBC.write( matrix );
An OD matrix that bellows to one (and only one) centroid configuration (GKCentroidConfiguration).
Definition: GKODMatrix.sip:29
@ eEID
Definition: GKODMatrix.sip:200

Constructor & Destructor Documentation

◆ GKODMatrixReaderODBC()

GKODMatrixReaderODBC::GKODMatrixReaderODBC ( )

Member Function Documentation

◆ getDbInfo()

const GKDataBaseInfo & GKODMatrixReaderODBC::getDbInfo ( ) const

Get the database to be used.

◆ read()

bool GKODMatrixReaderODBC::read ( GKODMatrix )
virtual

Reads a matrix from the database

Implements GKODMatrixReaderExternal.

◆ setDbInfo()

void GKODMatrixReaderODBC::setDbInfo ( const GKDataBaseInfo )

Set the database to be used.

◆ setRID()

void GKODMatrixReaderODBC::setRID ( int  )

Extra parameters ... no coded in Aimsun DB but supported in the ODBC DB.

Sets the identifier of the real data used to adjust a matrix.

◆ setTimeInt()

void GKODMatrixReaderODBC::setTimeInt ( int  )

Extra parameters ... no coded in Aimsun DB but supported in the ODBC DB.

Sets the number of intervals in the real data used to adjust a matrix.

◆ write()

bool GKODMatrixReaderODBC::write ( GKODMatrix )

Writes a matrix into the database

© Aimsun SLU
Aimsun ®