if (deployable.getDDBeanRoot().getDDBeanRootVersion().equals("1.5")) {
return new RARConfiguration(deployable, new ResourceAdapterDConfigRoot(deployable.getDDBeanRoot()));
}
String[] specVersion = deployable.getDDBeanRoot().getText("connector/spec-version");
if (specVersion.length > 0 && "1.0".equals(specVersion[0])) {
return new RARConfiguration(deployable, new ResourceAdapter_1_0DConfigRoot(deployable.getDDBeanRoot()));
}
throw new IllegalArgumentException("Unknown resource adapter version: " + deployable.getDDBeanRoot().getDDBeanRootVersion());
} else {
return null;
}