/** * Get all the portTypes defined in this Definition and * those in any imported Definitions in the WSDL tree. */ public Map getAllPortTypes() { Map allPortTypes = new HashMap(getPortTypes()); Map importMap = getImports(); Iterator mapItr = importMap.values().iterator(); while(mapItr.hasNext()) { Vector importDefs = (Vector) mapItr.next(); Iterator vecItr = importDefs.iterator(); while(vecItr.hasNext()) { Import importDef = (Import) vecItr.next(); Definition importedDef = importDef.getDefinition(); //importedDef may be null (e.g. if the javax.wsdl.importDocuments feature is disabled). if(importedDef != null) { allPortTypes.putAll(importedDef.getAllPortTypes()); } } } return allPortTypes; }
public Map getAllPortTypes() { return _def.getAllPortTypes(); }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } if (wsdlDefinition != null) { return wsdlDefinition.getAllPortTypes(); } return null; }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } if (wsdlDefinition != null) { return wsdlDefinition.getAllPortTypes(); } return null; }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } if (wsdlDefinition != null) { return wsdlDefinition.getAllPortTypes(); } return null; }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } if (wsdlDefinition != null) { return wsdlDefinition.getAllPortTypes(); } return null; }
public static boolean isPortTypeExisted(Definition wsdlDefinition, QName name) { Map<QName, PortType> portTypes = CastUtils.cast(wsdlDefinition.getAllPortTypes()); if (portTypes == null || portTypes.isEmpty()) { return false; } String existPortTypeName = null; PortType portType = null; try { for (Entry<QName, PortType> entry : portTypes.entrySet()) { existPortTypeName = entry.getKey().getLocalPart(); if (name.getLocalPart().contains(existPortTypeName)) { portType = entry.getValue(); break; } } } catch (Exception e) { portType = null; } return portType != null; }
public static boolean isPortTypeExisted(Definition wsdlDefinition, QName name) { Map<QName, PortType> portTypes = CastUtils.cast(wsdlDefinition.getAllPortTypes()); if (portTypes == null || portTypes.isEmpty()) { return false; } String existPortTypeName = null; PortType portType = null; try { for (QName existPortTypeQName : portTypes.keySet()) { existPortTypeName = existPortTypeQName.getLocalPart(); if (name.getLocalPart().contains(existPortTypeName)) { portType = portTypes.get(existPortTypeQName); break; } } } catch (Exception e) { portType = null; } if (portType == null) { return false; } return true; }
public static boolean isPortTypeExisted(Definition wsdlDefinition, QName name) { Map<QName, PortType> portTypes = CastUtils.cast(wsdlDefinition.getAllPortTypes()); if (portTypes == null || portTypes.isEmpty()) { return false; } String existPortTypeName = null; PortType portType = null; try { for (QName existPortTypeQName : portTypes.keySet()) { existPortTypeName = existPortTypeQName.getLocalPart(); if (name.getLocalPart().contains(existPortTypeName)) { portType = portTypes.get(existPortTypeQName); break; } } } catch (Exception e) { portType = null; } if (portType == null) { return false; } return true; }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } getWrappedDefinitionForUse(); Map results = null; if (wsdlDefinition != null) { results = wsdlDefinition.getAllPortTypes(); } doneUsingWrappedDefinition(); return results; }
public Map getAllPortTypes() { if (isDebugEnabled) { log.debug(myClassName + ".getAllPortTypes()"); } getWrappedDefinitionForUse(); Map results = null; if (wsdlDefinition != null) { results = wsdlDefinition.getAllPortTypes(); } doneUsingWrappedDefinition(); return results; }
private void collectValidationPoints() throws Exception { if (services.isEmpty()) { LOG.log(Level.WARNING, "WSDL document " + this.definition.getDocumentBaseURI() + " does not define any services"); //addWarning("WSDL document does not define any services"); Collection<QName> ports = CastUtils.cast(this.definition.getAllPortTypes().keySet()); portTypeRefNames.addAll(ports); } else { collectValidationPointsForBindings(); } collectValidationPointsForPortTypes(); collectValidationPointsForMessages(); }
/** * Get all the portTypes defined in this Definition and * those in any imported Definitions in the WSDL tree. */ public Map getAllPortTypes() { Map allPortTypes = new HashMap(getPortTypes()); Map importMap = getImports(); Iterator mapItr = importMap.values().iterator(); while(mapItr.hasNext()) { Vector importDefs = (Vector) mapItr.next(); Iterator vecItr = importDefs.iterator(); while(vecItr.hasNext()) { Import importDef = (Import) vecItr.next(); Definition importedDef = importDef.getDefinition(); //importedDef may be null (e.g. if the javax.wsdl.importDocuments feature is disabled). if(importedDef != null) { allPortTypes.putAll(importedDef.getAllPortTypes()); } } } return allPortTypes; }
private void collectValidationPoints() throws Exception { if (services.isEmpty()) { LOG.log(Level.WARNING, "WSDL document " + this.definition.getDocumentBaseURI() + " does not define any services"); //addWarning("WSDL document does not define any services"); Collection<QName> ports = CastUtils.cast(this.definition.getAllPortTypes().keySet()); portTypeRefNames.addAll(ports); } else { collectValidationPointsForBindings(); } collectValidationPointsForPortTypes(); collectValidationPointsForMessages(); }
private List<PortType> getPortTypeList() throws Exception { Map<QName, PortType> portTypes = CastUtils.cast(def.getAllPortTypes()); List<PortType> intfs = null; if (portTypes == null) { org.apache.cxf.common.i18n.Message msg = new org.apache.cxf.common.i18n.Message( "No PortTypes defined in wsdl", LOG); throw new Exception(msg.toString()); } PortType portType = null; intfs = new ArrayList<>(); if (portTypes.size() == 1) { portType = portTypes.values().iterator().next(); interfaceNames.add(portType.getQName().getLocalPart()); intfs.add(portType); } else if (portTypes.size() > 1) { if (def.getAllBindings().size() > 0) { throwMultipleMultipleTypeException(CastUtils.cast(def.getAllBindings().keySet(), QName.class)); } for (PortType port : portTypes.values()) { interfaceNames.add(port.getQName().getLocalPart()); intfs.add(port); } } return intfs; }
Definition readWSDL = newWSDLReader.readWSDL(null, doc); Map allPortTypes = readWSDL.getAllPortTypes(); Iterator ports = allPortTypes.keySet().iterator(); while (ports.hasNext()) //for each port
PortType portType = null; Map<QName, PortType> portTypes = CastUtils.cast(def.getAllPortTypes()); if (portTypes != null) { for (Entry<QName, PortType> entry : portTypes.entrySet()) {
List<TModel> tModels = new ArrayList<TModel>(); Map<QName, PortType> portTypes = (Map<QName, PortType>) wsdlDefinition.getAllPortTypes(); tModels.addAll(createWSDLPortTypeTModels(genericWSDLURL, portTypes));
wsdlInterface.setUnresolved(false); wsdlInterface.setRemotable(true); PortType portType = (PortType)def.getAllPortTypes().values().iterator().next(); wsdlInterface.setPortType(portType);
Collection<PortType> portTypes = CastUtils.cast(definition.getAllPortTypes().values()); for (PortType port : portTypes) { def.addPortType(port);