String opInputName = input.getName();
protected void printInput(Input input, Definition def, PrintWriter pw) throws WSDLException { if (input != null) { String tagName = DOMUtils.getQualifiedValue(Constants.NS_URI_WSDL, Constants.ELEM_INPUT, def); pw.print(" <" + tagName); DOMUtils.printAttribute(Constants.ATTR_NAME, input.getName(), pw); Message message = input.getMessage(); if (message != null) { DOMUtils.printQualifiedAttribute(Constants.ATTR_MESSAGE, message.getQName(), def, pw); } printExtensibilityAttributes(Input.class, input, def, pw); pw.println('>'); printDocumentation(input.getDocumentationElement(), def, pw); List extElements = input.getExtensibilityElements(); printExtensibilityElements(Input.class, extElements, def, pw); pw.println(" </" + tagName + '>'); } }
@RequestMapping(value="/rest/greetMe", method= RequestMethod.GET) public @ResponseBody Greeting sayHello( @RequestParam(value = "name", required = false, defaultValue = "Stranger") String name, @RequestParam(value = "language", required = false, defaultValue = "en") String language) { return new Greeting(counter.incrementAndGet(), String.format(getTemplate(language), name)); } @RequestMapping(value="/rest/greetMe", method= RequestMethod.POST) public @ResponseBody Greeting sayHello( @RequestBody(required = true) Input input) { return new Greeting(counter.incrementAndGet(), String.format(getTemplate(input.getLanguage()), input.getName())); }
/** * Called after the {@link BindingInput} has been created. Subclasses can override this method to define the name, * or add extensions to it. * * <p>Default implementation set the name of the binding input to the name of the input. * * @param definition the WSDL4J {@code Definition} * @param bindingInput the WSDL4J {@code BindingInput} * @param input the corresponding WSDL4J {@code Input} @throws WSDLException in case of errors */ protected void populateBindingInput(Definition definition, BindingInput bindingInput, Input input) throws WSDLException { bindingInput.setName(input.getName()); }
protected void configureBindingInput(BindingInput bindingInput, Input input) throws WSDLException { bindingInput.setName(input.getName()); }
/** * Called after the {@link BindingInput} has been created. Subclasses can override this method to define the name, * or add extensions to it. * <p/> * Default implementation set the name of the binding input to the name of the input. * * @param definition the WSDL4J <code>Definition</code> * @param bindingInput the WSDL4J <code>BindingInput</code> * @param input the corresponding WSDL4J <code>Input</code> @throws WSDLException in case of errors */ protected void populateBindingInput(Definition definition, BindingInput bindingInput, Input input) throws WSDLException { bindingInput.setName(input.getName()); }
/** * Called after the {@link BindingInput} has been created. Subclasses can override this method to define the name, * or add extensions to it. * * <p>Default implementation set the name of the binding input to the name of the input. * * @param definition the WSDL4J {@code Definition} * @param bindingInput the WSDL4J {@code BindingInput} * @param input the corresponding WSDL4J {@code Input} @throws WSDLException in case of errors */ protected void populateBindingInput(Definition definition, BindingInput bindingInput, Input input) throws WSDLException { bindingInput.setName(input.getName()); }
public static String getAction(Operation op) { Input input = op.getInput(); Object attr = input.getExtensionAttribute(WsaConstants.ACTION_QNAME); if (attr == null) { Object[] filler = { op.getName(), input.getName(), input.getExtensionAttributes().keySet() }; throw new RuntimeException(_MESSAGES.get("NoActionOnInput", filler)); } return attr instanceof String ? (String)attr : ((QName)attr).getLocalPart(); }
private BindingInput getBindingInput(Input input, String operationName) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); //This ext element in some scenario is optional, but if provided, won't cause error bi.addExtensibilityElement(getXMLBody(BindingInput.class, operationName)); return bi; }
private static BindingInput getBindingInput(Input input, Definition wsdlDefinition, ExtensionRegistry extReg) throws Exception { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); bi.addExtensibilityElement(getSoapBody(BindingInput.class, extReg)); return bi; }
private BindingInput getBindingInput(Input input) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); // As command line won't specify the details of body/header for message // parts // All input message's parts will be added into one soap body element bi.addExtensibilityElement(getSoapBody(BindingInput.class)); return bi; }
private static BindingInput getBindingInput(Input input, Definition wsdlDefinition, ExtensionRegistry extReg) throws Exception { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); bi.addExtensibilityElement(getSoapBody(BindingInput.class, extReg)); return bi; }
private static BindingInput getBindingInput(Input input, Definition wsdlDefinition, ExtensionRegistry extReg) throws Exception { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); bi.addExtensibilityElement(getSoapBody(BindingInput.class, extReg)); return bi; }
private BindingInput getBindingInput(Input input) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); // As command line won't specify the details of body/header for message // parts // All input message's parts will be added into one soap body element bi.addExtensibilityElement(getSoapBody(BindingInput.class)); return bi; }
private BindingInput getBindingInput(Input input, String operationName) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); //This ext element in some scenario is optional, but if provided, won't cause error bi.addExtensibilityElement(getXMLBody(BindingInput.class, operationName)); return bi; }
private BindingInput getBindingInput(Input input) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); // As command line won't specify the details of body/header for message // parts // All input message's parts will be added into one soap body element bi.addExtensibilityElement(getSoapBody(BindingInput.class)); return bi; }
private BindingInput getBindingInput(Input input, String operationName) throws ToolException { BindingInput bi = wsdlDefinition.createBindingInput(); bi.setName(input.getName()); //This ext element in some scenario is optional, but if provided, won't cause error bi.addExtensibilityElement(getXMLBody(BindingInput.class, operationName)); return bi; }
public Selector(Resource aFile, Service aService, Port aPort, Operation aOperation, String aId) { file = aFile; service = aService.getQName(); port = aPort.getName(); operation = aOperation.getName(); String inputName = aOperation.getInput().getName(); input = (inputName != null) ? inputName : ":none"; String outputName = aOperation.getOutput().getName(); output = (outputName != null) ? outputName : ":none"; id = aId; } }