// interfaces config (ESB, MQ)
int infList = extConfig.getList("Interfaces.Interface.name")
.size();
if (infList > 0) {
for (int i = 0; i < infList; i++) {
InterfaceConfig interfaceConfig = new InterfaceConfig();
InterfaceMqConfig fromMq = new InterfaceMqConfig();
InterfaceMqConfig toMq = new InterfaceMqConfig();
HierarchicalConfiguration fromMqConfig = extConfig
.configurationAt("Interfaces.Interface(" + i
+ ").FromMq");
HierarchicalConfiguration toMqConfig = extConfig
.configurationAt("Interfaces.Interface(" + i
+ ").ToMq");
String name = extConfig
.getString("Interfaces.Interface(" + i
+ ").name");
String xsd = extConfig
.getString("Interfaces.Interface(" + i
+ ").xsd");
String className = extConfig
.getString("Interfaces.Interface(" + i
+ ").classname");
String regExp = extConfig
.getString("Interfaces.Interface(" + i
+ ").regexp");
interfaceConfig.setName(name);
interfaceConfig.setXsd(xsd);
interfaceConfig.setClassName(className);
interfaceConfig.setRegexp(regExp);
LOG.debug("FROM URL : {}", fromMqConfig.getString("url"));
fromMq.setUrl(fromMqConfig.getString("url"));
fromMq.setUserName(fromMqConfig.getString("username"));
fromMq.setPassword(fromMqConfig.getString("password"));
fromMq.setQueueName(fromMqConfig.getString("queue"));
fromMq.setEnabled(fromMqConfig.getString("enabled"));
interfaceConfig.setFromMq(fromMq);
List<Object> from = fromMqConfig.getList("queue");
if (from != null && from.size() > 0) {
for (int j = 0; j < from.size(); j++) {
fromQueueList.add(from.get(j) == null ? ""
: from.get(j).toString());
LOG.debug("Loaded Q from config : <{}>", from
.get(j).toString());
}
}
List<Object> fromTopics = toMqConfig.getList("topic");
if (fromTopics != null && fromTopics.size() > 0) {
for (int j = 0; j < fromTopics.size(); j++) {
fromTopicList
.add(fromTopics.get(j) == null ? ""
: fromTopics.get(j).toString());
}
}
LOG.debug("URL : {}", toMqConfig.getString("url"));
toMq.setUrl(toMqConfig.getString("url"));
toMq.setUserName(toMqConfig.getString("username"));
toMq.setPassword(toMqConfig.getString("password"));
toMq.setEnabled(toMqConfig.getString("enabled"));
interfaceConfig.setToMq(toMq);
List<Object> to = toMqConfig.getList("queue");
if (to != null && to.size() > 0) {
for (int j = 0; j < to.size(); j++) {
toQueueList.add(to.get(j) == null ? "" : to