/** * Gets the name of the binding type associated to the specified Port. * * @param port Port to process * @return Binding class name */ protected final String getBindingType(Port port) { Binding binding = port.getBinding(); if (binding == null) { return null; } BindingEntry bEntry = symbolTable.getBindingEntry(binding.getQName()); // If this isn't an SOAP binding, skip it if (bEntry == null || bEntry.getBindingType() != BindingEntry.TYPE_SOAP) { return null; } return (String) bEntry.getDynamicVar(JavaBindingWriter.INTERFACE_NAME); }
/** * Constructor. * * @param emitter * @param bEntry * @param symbolTable */ public JavaStubWriter(Emitter emitter, BindingEntry bEntry, SymbolTable symbolTable) { super(emitter, bEntry.getName() + "Stub", "stub"); this.bEntry = bEntry; this.binding = bEntry.getBinding(); this.symbolTable = symbolTable; } // ctor
BindingEntry bEntry = new BindingEntry(binding); bEntry.setBindingType(BindingEntry.TYPE_SOAP); bEntry.setBindingStyle(Style.RPC); bEntry.setBindingType(BindingEntry.TYPE_HTTP_POST); } else { bEntry.setBindingType(BindingEntry.TYPE_HTTP_GET); bEntry.setBindingType(BindingEntry.TYPE_SOAP); bEntry.setBindingStyle(Style.RPC); Use inputBodyType = bEntry.getInputBodyType(operation); Use outputBodyType = bEntry.getOutputBodyType(operation); bEntry.setHasLiteral(true); bEntry.setFaultBodyTypeMap(operation, faultMap); bEntry.setFaults(faultMap);
boolean hasLiteral = bEntry.hasLiteral(); boolean hasMIME = Utils.hasMIME(bEntry); String prefix = WSDDConstants.NS_PREFIX_WSDD_JAVA; String styleStr = ""; Iterator iterator = bEntry.getBinding().getExtensibilityElements().iterator(); use = Use.LITERAL; } else { styleStr = " style=\"" + bEntry.getBindingStyle().getName() + "\""; writeDeployTypes(pw, bEntry.getBinding(), hasLiteral, hasMIME, use); pw.println(" </service>");
if (bEntry.getBindingType() != BindingEntry.TYPE_SOAP) { continue; Binding binding = bEntry.getBinding(); Collection bindOperations = bEntry.getOperations(); PortType portType = binding.getPortType(); HashMap parameters = new HashMap(); bEntry.setParameters(parameters);
Use use = bEntry.getInputBodyType(operation.getOperation()); Style style = Style.getStyle(opStyle, bEntry.getBindingStyle()); bEntry.getBinding().getExtensibilityElements().iterator(); if (bEntry.isOperationDIME(operation.getOperation().getName())) { pw.println( " _call.setProperty(_call.ATTACHMENT_ENCAPSULATION_FORMAT, _call.ATTACHMENT_ENCAPSULATION_FORMAT_DIME);");
SymbolTable symbolTable = service.getWSDLParser().getSymbolTable(); BindingEntry bEntry = symbolTable.getBindingEntry(binding.getQName()); Parameters parameters = bEntry.getParameters(bop.getOperation()); Map faultMap = bEntry.getFaults(); Use use = bEntry.getInputBodyType(bop.getOperation()); setOperationUse(use); if (use == Use.LITERAL) { Style style = Style.getStyle(opStyle, bEntry.getBindingStyle()); if (style == Style.DOCUMENT && symbolTable.isWrapped()) { style = Style.WRAPPED;
Document doc) { if (entry.getBindingType() == BindingEntry.TYPE_SOAP) { Binding binding = entry.getBinding(); entry.setIsReferenced(true); } else { entry.setIsReferenced(true);
return; setMIMEInfo(param, bindingEntry.getMIMEInfo(opName, partName)); if (bindingEntry.isInHeaderPart(opName, partName)) { isHeader = true; param.setInHeader(true); if (bindingEntry.isOutHeaderPart(opName, partName)) { isHeader = true; param.setOutHeader(true); if (isHeader && (bindingEntry.getBinding() != null)) { List list = bindingEntry.getBinding().getBindingOperations();
throws IOException { Binding binding = bEntry.getBinding(); String className = bEntry.getName(); Map faultMap = bEntry.getFaults(); ArrayList faults = null;
+ Messages.getMessage("mustSetStyle")); if (bEntry.hasLiteral()) { pw.println(" _call.setEncodingStyle(null);"); } else { Iterator iterator = bEntry.getBinding().getExtensibilityElements().iterator(); BindingOperation operation = (BindingOperation) operations.get(i); Parameters parameters = bEntry.getParameters(operation.getOperation());
(String) bEntry.getDynamicVar(JavaBindingWriter.INTERFACE_NAME); String implType = portTypeName + " impl"; bEntry.getParameters(bindingOper.getOperation()); if (bEntry.getFaults() != null) { ArrayList faults = (ArrayList) bEntry.getFaults().get(bindingOper); implementationClassName = bEntry.getName() + "Impl"; pw.println(" this.impl = new " + implementationClassName + "();"); pw.println(" }"); BindingOperation operation = (BindingOperation) operations.get(i); Parameters parameters = bEntry.getParameters(operation.getOperation());
if ((bEntry.getBindingStyle() == Style.DOCUMENT) && symbolTable.isWrapped()) { Input input = operation.getInput(); if (bEntry.getInputBodyType(operation) == Use.ENCODED && (ns == null || ns.length() == 0)) { log.warn(Messages.getMessage("badNamespaceForOperation00", bEntry.getName(), operation.getName())); if (bEntry.getInputBodyType(operation) == Use.ENCODED && (ns == null || ns.length() == 0)) { log.warn(Messages.getMessage("badNamespaceForOperation00", bEntry.getName(), operation.getName()));
bEntry.getParameters(operation.getOperation()); Style style = Style.getStyle(opStyle, bEntry.getBindingStyle()); Use use = bEntry.getInputBodyType(operation.getOperation());
/** * The --all flag is set on the command line (or generateAll(true) is called * on WSDL2Java). Set all symbols as referenced (except nonSOAP bindings * which we don't know how to deal with). */ protected void setAllReferencesToTrue() { Iterator it = symbolTable.getHashMap().values().iterator(); while (it.hasNext()) { Vector v = (Vector) it.next(); for (int i = 0; i < v.size(); ++i) { SymTabEntry entry = (SymTabEntry) v.elementAt(i); if ((entry instanceof BindingEntry) && ((BindingEntry) entry).getBindingType() != BindingEntry.TYPE_SOAP) { entry.setIsReferenced(false); } else { entry.setIsReferenced(true); } } } } // setAllReferencesToTrue
/** * Returns "implements <SEI>, org.apache.axis.wsdl.Skeleton ". * * @return */ protected String getImplementsText() { return "implements " + bEntry.getDynamicVar(JavaBindingWriter.INTERFACE_NAME) + ", org.apache.axis.wsdl.Skeleton "; } // getImplementsText
literalInput = bEntry.getInputBodyType(operation) == Use.LITERAL; literalOutput = bEntry.getOutputBodyType(operation) == Use.LITERAL;
symbolTable.getBindingEntry(binding.getQName()); if (entry.isReferenced()) { Map faultMap = entry.getFaults(); Iterator it = faultMap.values().iterator();
&& (bindingEntry == null || bindingEntry.getMIMETypes().size() == 0)) { : bindingEntry.getBinding().getQName().toString();
Binding binding = bEntry.getBinding(); Map faultMap = bEntry.getFaults(); ArrayList faults = null;