tempDatasource.setDatabasePort(Integer.parseInt(myTextFieldDatabasePort.getText()));
}
catch (NumberFormatException e){
tempDatasource.setDatabasePort(1521);
}
tempDatasource.connect();
tempDatasource.setName(myTextFieldDatabaseName.getText());
// save the configuration information.
System.getProperties().setProperty(Constants.getApplicationName()+"."+SERVERNAME_TAG, tempDatasource.getDatabaseServername());
System.getProperties().setProperty(Constants.getApplicationName()+"."+DATABASENAME_TAG, tempDatasource.getDatabaseName());