String name = factoryProp.getName();
ModelNode factoryValue = factoryProp.getValue();
String jndi = factoryValue.get("entries").asList().get(0).asString();
ConnectionFactory connectionFactory = factoryAdapter.fromDMR(factoryValue);
connectionFactory.setName(name);
connectionFactory.setJndiName(jndi);
if (factoryValue.hasDefined("connector")) {
List<Property> items = factoryValue.get("connector").asPropertyList();
String list = "";
for (Property item : items)
list += " " + item.getName();
connectionFactory.setConnector(list);
}
factoryModels.add(connectionFactory);
}