#include <TdkDatabaseDlgController.h>
Inheritance diagram for TdkDatabaseDlgController:
Behavioral Methods | |
Methods related connect database dialog behavior. | |
virtual void | setInitialState () |
Sets the initial state of the dialog. | |
virtual void | update (TdkSubject *changedObject) |
This method is called when the user interacts with the dialog. | |
virtual bool | getDbList (const std::string &dbType, const std::string &host, const std::string &user, const std::string &password) |
Method updates the list of terralib databases avaliable on selected DBMS. | |
virtual std::string | dlgName () |
Retrieves dialog's definiton name. | |
virtual void | setApplication (TdkApplication *app) |
Sets TdkApplication pointer. | |
virtual int | getActionId (const string &action) |
Retrieves the action generated by user. Given a action name retrives the correspondent int value. | |
static bool | isConnectOperation () |
Method used by sinalize connect database operation. | |
virtual TdkConDescriptor * | getDbDescriptor () throw (TdkException) |
Retrieves the connection descriptor, based on dialogs attributes. | |
virtual void | directoryClicked () |
Action called on directory button clicked. | |
virtual void | dbmsChanged (const std::string &dbms) |
Action called on dbms element list changed. | |
virtual void | setConnectionMode (const std::string &dbType) |
Changes the dialog to connect state. Enables fields based on dbType parameter. | |
virtual void | setCreationMode (const std::string &dbType) |
Changes the dialog to create state. Enables fields based on dbType parameter. | |
virtual void | setDBMS_Mode (const std::string &dbType) |
Changes the dialog state to a specific database driver. Enables fields based on dbType parameter. | |
virtual TdkConDescriptor * | createDbDescriptor (const std::string &dbType, const std::string &dbName, const std::string &host, const std::string &user, const std::string &pword) |
Retrieves the TdkConDescriptor based on dialog parameters. | |
virtual void | okClicked () |
Action called on ok button clicked. | |
Public Member Functions | |
Constructor and Destructor Methods | |
Methods related to instantiation and destruction. | |
TdkDatabaseDlgController (TdkDatabaseDlg *dlg) | |
Constructor. | |
virtual | ~TdkDatabaseDlgController () |
Virtual destructor. | |
Private Attributes | |
TdkApplication * | _app |
Pointer to TdkApplication. | |
Static Private Attributes | |
static bool | _isConnectOp = true |
Flag that sinalizes a connection operation. |
TODO: 1)
TdkDatabaseDlgController::TdkDatabaseDlgController | ( | TdkDatabaseDlg * | dlg | ) |
Constructor.
dlg | Pointer to connect database dialog. |
TdkDatabaseDlgController::~TdkDatabaseDlgController | ( | ) | [virtual] |
Virtual destructor.
void TdkDatabaseDlgController::setInitialState | ( | ) | [virtual] |
void TdkDatabaseDlgController::update | ( | TdkSubject * | changedObject | ) | [virtual] |
This method is called when the user interacts with the dialog.
changedObject | Object that signals a change. |
Implements TdkObserver.
bool TdkDatabaseDlgController::getDbList | ( | const std::string & | dbType, | |
const std::string & | host, | |||
const std::string & | user, | |||
const std::string & | password | |||
) | [virtual] |
Method updates the list of terralib databases avaliable on selected DBMS.
dbType | Database driver type. | |
host | Host name. | |
user | User name. | |
password | User password. |
std::string TdkDatabaseDlgController::dlgName | ( | ) | [virtual] |
Retrieves dialog's definiton name.
Implements TdkDlgController.
bool TdkDatabaseDlgController::isConnectOperation | ( | ) | [static] |
Method used by sinalize connect database operation.
void TdkDatabaseDlgController::setApplication | ( | TdkApplication * | app | ) | [virtual] |
int TdkDatabaseDlgController::getActionId | ( | const string & | action | ) | [virtual] |
Retrieves the action generated by user. Given a action name retrives the correspondent int value.
Reimplemented from TdkDlgController.
TdkConDescriptor * TdkDatabaseDlgController::getDbDescriptor | ( | ) | throw (TdkException) [protected, virtual] |
Retrieves the connection descriptor, based on dialogs attributes.
void TdkDatabaseDlgController::directoryClicked | ( | ) | [protected, virtual] |
Action called on directory button clicked.
void TdkDatabaseDlgController::dbmsChanged | ( | const std::string & | dbms | ) | [protected, virtual] |
Action called on dbms element list changed.
dbms | Name of dbms used. |
void TdkDatabaseDlgController::setConnectionMode | ( | const std::string & | dbType | ) | [protected, virtual] |
Changes the dialog to connect state. Enables fields based on dbType parameter.
dbType | Name of dbms used. |
void TdkDatabaseDlgController::setCreationMode | ( | const std::string & | dbType | ) | [protected, virtual] |
Changes the dialog to create state. Enables fields based on dbType parameter.
dbType | Name of dbms used. |
void TdkDatabaseDlgController::setDBMS_Mode | ( | const std::string & | dbType | ) | [protected, virtual] |
Changes the dialog state to a specific database driver. Enables fields based on dbType parameter.
dbType | Name of dbms used. |
TdkConDescriptor * TdkDatabaseDlgController::createDbDescriptor | ( | const std::string & | dbType, | |
const std::string & | dbName, | |||
const std::string & | host, | |||
const std::string & | user, | |||
const std::string & | pword | |||
) | [protected, virtual] |
Retrieves the TdkConDescriptor based on dialog parameters.
dbType | Name of dbms used. | |
dbName | Terralib database name. | |
host | Host name. | |
user | User name. | |
pword | User password. |
void TdkDatabaseDlgController::okClicked | ( | ) | [protected, virtual] |
Action called on ok button clicked.
TdkApplication* TdkDatabaseDlgController::_app [private] |
Pointer to TdkApplication.
bool TdkDatabaseDlgController::_isConnectOp = true [static, private] |
Flag that sinalizes a connection operation.