throw new IllegalStateException("Cannot obtain endpoint meta data for: " + portName);
epMetaData.clearHandlers();
for (HandlerInfo info : infos)
{
HandlerMetaDataJAXRPC handler = new HandlerMetaDataJAXRPC(HandlerType.ENDPOINT);
handler.setEndpointMetaData(epMetaData);
handler.setHandlerClassName(info.getHandlerClass().getName());
handler.setSoapRoles(roles);
// copy headers
Set<QName> headers = new HashSet<QName>();
for (QName header : info.getHeaders())
headers.add(header);
handler.setSoapHeaders(headers);
// copy init params
List<UnifiedInitParamMetaData> initParams = new ArrayList<UnifiedInitParamMetaData>();
Iterator<Map.Entry> entries = info.getHandlerConfig().entrySet().iterator();
while (entries.hasNext())
{
Map.Entry entry = entries.next();
String key = (String)entry.getKey();
Object value = entry.getValue();
if (value instanceof String)
initParams.add(new UnifiedInitParamMetaData(key, (String)value));
}
handler.setInitParams(initParams);
epMetaData.addHandler(handler);
log.debug("Add handler to: " + portName + handler);
}
}