use of com.cubrid.cubridmanager.core.cubrid.table.model.DBClasses in project cubrid-manager by CUBRID.
the class GetClassListTaskTest method testClassInfo.
public void testClassInfo() {
if (StringUtil.isEqual(SystemParameter.getParameterValue("useMockTest"), "n"))
return;
System.out.println("<table.classinfo.001.req.txt>");
GetClassListTask task = new GetClassListTask(serverInfo);
task.setDbName("demodb");
task.setDbStatus(OnOffType.OFF);
task.execute();
assertTrue(task.isSuccess());
DBClasses classes = task.getDbClassInfo();
ClassList classList = classes.getSystemClassList();
List<ClassItem> list = classList.getClassList();
assertEquals("db_root", list.get(0).getClassname());
}
use of com.cubrid.cubridmanager.core.cubrid.table.model.DBClasses in project cubrid-manager by CUBRID.
the class ModelUtil method getClassList.
/**
* Parse SchemaInfo message TreeNode and return SchemaInfo Object
*
* @param classesinfo TreeNode
* @return DBClasses
*/
public static DBClasses getClassList(TreeNode classesinfo) {
DBClasses schema = new DBClasses();
SocketTask.setFieldValue(classesinfo, schema);
return schema;
}
use of com.cubrid.cubridmanager.core.cubrid.table.model.DBClasses in project cubrid-manager by CUBRID.
the class SelectTablesPage method pageChanged.
/**
* @see org.eclipse.jface.dialogs.IPageChangedListener#pageChanged(org.eclipse.jface.dialogs.PageChangedEvent)
* @param event PageChangedEvent
*/
public void pageChanged(PageChangedEvent event) {
IWizardPage page = (IWizardPage) event.getSelectedPage();
if (page.getName().equals(PAGENAME)) {
SelectDatabasePage selectDatabasePage = (SelectDatabasePage) getWizard().getPage(SelectDatabasePage.PAGENAME);
String dbName = selectDatabasePage.getDbName();
String dbaPassword = selectDatabasePage.getDbaPassword();
if (host != null && host.isValid()) {
String ip = host.getIp();
String port = host.getPort();
String userName = host.getUserName();
String password = host.getPassword();
GetAllClassesTaskExecutor taskExcutor = new GetAllClassesTaskExecutor(getShell(), ip, port, userName, password, dbName, dbaPassword);
new ExecTaskWithProgress(taskExcutor).exec();
if (taskExcutor.isSuccess()) {
DBClasses dbClasses = taskExcutor.getDBClasses();
selectTableComp.fillTableViewer(dbClasses);
selectTableComp.setReplAllTables(master.isReplicateAll());
selectTableComp.setSelectedTableList(master.getReplicatedClassList());
setErrorMessage(null);
setPageComplete(isEditable);
} else {
setErrorMessage(Messages.errPreviousPage);
setPageComplete(false);
}
}
}
}
Aggregations