final JdbcConnectionDefinition connectionDefinition =
(JdbcConnectionDefinition) getDialogModel().getConnections().getSelectedItem();
if (connectionDefinition instanceof JndiConnectionDefinition)
{
final JndiConnectionDefinition jcd = (JndiConnectionDefinition) connectionDefinition;
final JndiConnectionProvider provider = new JndiConnectionProvider();
provider.setConnectionPath(jcd.getJndiName());
provider.setUsername(jcd.getUsername());
provider.setPassword(jcd.getPassword());
return new SimpleLegacyBandedMDXDataFactory(provider);
}
else if (connectionDefinition instanceof DriverConnectionDefinition)
{
final DriverConnectionDefinition dcd = (DriverConnectionDefinition) connectionDefinition;