gpt4 book ai didi

com.sun.xml.ws.streaming.XMLStreamReaderUtil.nextElementContent()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-19 17:10:40 26 4
gpt4 key购买 nike

本文整理了Java中com.sun.xml.ws.streaming.XMLStreamReaderUtil.nextElementContent()方法的一些代码示例,展示了XMLStreamReaderUtil.nextElementContent()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XMLStreamReaderUtil.nextElementContent()方法的具体详情如下:
包路径:com.sun.xml.ws.streaming.XMLStreamReaderUtil
类名称:XMLStreamReaderUtil
方法名:nextElementContent

XMLStreamReaderUtil.nextElementContent介绍

暂无

代码示例

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static void skipTextElement(XMLStreamReader reader) {
  XMLStreamReaderUtil.nextContent(reader);
  XMLStreamReaderUtil.nextElementContent(reader);
  XMLStreamReaderUtil.nextElementContent(reader);
}

代码示例来源:origin: com.sun.xml.ws/rt

private static void skipTextElement(XMLStreamReader reader) {
  XMLStreamReaderUtil.nextContent(reader);
  XMLStreamReaderUtil.nextElementContent(reader);
  XMLStreamReaderUtil.nextElementContent(reader);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static boolean hasWSDLDefinitions(XMLStreamReader reader) {
  XMLStreamReaderUtil.nextElementContent(reader);
  return reader.getName().equals(WSDLConstants.QNAME_DEFINITIONS);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

public static void toNextTag(XMLStreamReader reader, QName name) {
  // skip any whitespace
  if (reader.getEventType() != XMLStreamConstants.START_ELEMENT &&
      reader.getEventType() != XMLStreamConstants.END_ELEMENT) {
    XMLStreamReaderUtil.nextElementContent(reader);
  }
  if(reader.getEventType() == XMLStreamConstants.END_ELEMENT && name.equals(reader.getName())) {
    XMLStreamReaderUtil.nextElementContent(reader); 
  }
}

代码示例来源:origin: com.sun.xml.ws/rt

public static void toNextTag(XMLStreamReader reader, QName name) {
  // skip any whitespace
  if (reader.getEventType() != XMLStreamConstants.START_ELEMENT &&
      reader.getEventType() != XMLStreamConstants.END_ELEMENT) {
    XMLStreamReaderUtil.nextElementContent(reader);
  }
  if(reader.getEventType() == XMLStreamConstants.END_ELEMENT && name.equals(reader.getName())) {
    XMLStreamReaderUtil.nextElementContent(reader); 
  }
}

代码示例来源:origin: com.sun.xml.ws/rt

private static void skipChain(XMLStreamReader reader) {
  while (XMLStreamReaderUtil.nextContent(reader) !=
      XMLStreamConstants.END_ELEMENT ||
      !reader.getName().equals(QNAME_HANDLER_CHAIN)) {}
  XMLStreamReaderUtil.nextElementContent(reader);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static void skipInitParamElement(XMLStreamReader reader) {
  int state;
  do {
    state = XMLStreamReaderUtil.nextContent(reader);
  } while (state != XMLStreamReader.END_ELEMENT ||
      !reader.getName().equals(QNAME_HANDLER_PARAM));
  XMLStreamReaderUtil.nextElementContent(reader);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static void goToEnd(XMLStreamReader reader) {
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    XMLStreamReaderUtil.skipElement(reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static void skipChain(XMLStreamReader reader) {
  while (XMLStreamReaderUtil.nextContent(reader) !=
      XMLStreamConstants.END_ELEMENT ||
      !reader.getName().equals(QNAME_HANDLER_CHAIN)) {}
  XMLStreamReaderUtil.nextElementContent(reader);
}

代码示例来源:origin: com.sun.xml.ws/rt

private static void goToEnd(XMLStreamReader reader) {
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    XMLStreamReaderUtil.skipElement(reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

static String documentRootNamespace(Source src, boolean disableXmlSecurity) throws XMLStreamException {
    XMLInputFactory factory;
    factory = XmlUtil.newXMLInputFactory(!disableXmlSecurity);
    XMLStreamReader streamReader = factory.createXMLStreamReader(src);
    XMLStreamReaderUtil.nextElementContent(streamReader);
    String namespaceURI = streamReader.getName().getNamespaceURI();
    XMLStreamReaderUtil.close(streamReader);
    return namespaceURI;
  }
}

代码示例来源:origin: com.sun.xml.ws/rt

static String documentRootNamespace(Source src, boolean disableXmlSecurity) throws XMLStreamException {
    XMLInputFactory factory;
    factory = XmlUtil.newXMLInputFactory(!disableXmlSecurity);
    XMLStreamReader streamReader = factory.createXMLStreamReader(src);
    XMLStreamReaderUtil.nextElementContent(streamReader);
    String namespaceURI = streamReader.getName().getNamespaceURI();
    XMLStreamReaderUtil.close(streamReader);
    return namespaceURI;
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private static void parseMimeMultipartBinding(XMLStreamReader reader, EditableWSDLBoundOperation op, BindingMode mode) {
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    QName name = reader.getName();
    if (MIMEConstants.QNAME_PART.equals(name)) {
      parseMIMEPart(reader, op, mode);
    } else {
      XMLStreamReaderUtil.skipElement(reader);
    }
  }
}

代码示例来源:origin: com.sun.xml.ws/rt

public static final Message decode(SOAPVersion soapVersion, XMLStreamReader reader, @NotNull AttachmentSet attachmentSet) {
  // Move to soap:Envelope and verify
  if(reader.getEventType()!=XMLStreamConstants.START_ELEMENT)
    XMLStreamReaderUtil.nextElementContent(reader);
  XMLStreamReaderUtil.verifyReaderState(reader,XMLStreamConstants.START_ELEMENT);
  if (SOAP_ENVELOPE.equals(reader.getLocalName()) && !soapVersion.nsUri.equals(reader.getNamespaceURI())) {
    throw new VersionMismatchException(soapVersion, soapVersion.nsUri, reader.getNamespaceURI());
  }
  XMLStreamReaderUtil.verifyTag(reader, soapVersion.nsUri, SOAP_ENVELOPE);
  return new StreamMessage(soapVersion, reader, attachmentSet);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

public static final Message decode(SOAPVersion soapVersion, XMLStreamReader reader, @NotNull AttachmentSet attachmentSet) {
  // Move to soap:Envelope and verify
  if(reader.getEventType()!=XMLStreamConstants.START_ELEMENT)
    XMLStreamReaderUtil.nextElementContent(reader);
  XMLStreamReaderUtil.verifyReaderState(reader,XMLStreamConstants.START_ELEMENT);
  if (SOAP_ENVELOPE.equals(reader.getLocalName()) && !soapVersion.nsUri.equals(reader.getNamespaceURI())) {
    throw new VersionMismatchException(soapVersion, soapVersion.nsUri, reader.getNamespaceURI());
  }
  XMLStreamReaderUtil.verifyTag(reader, soapVersion.nsUri, SOAP_ENVELOPE);
  return new StreamMessage(soapVersion, reader, attachmentSet);
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private void parseFaultBinding(XMLStreamReader reader, EditableWSDLBoundOperation bindingOp) {
  String faultName = ParserUtil.getMandatoryNonEmptyAttribute(reader, "name");
  EditableWSDLBoundFault wsdlBoundFault = new WSDLBoundFaultImpl(reader, faultName, bindingOp);
  bindingOp.addFault(wsdlBoundFault);
  extensionFacade.bindingOperationFaultAttributes(wsdlBoundFault, reader);
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    extensionFacade.bindingOperationFaultElements(wsdlBoundFault, reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private void parsePortTypeOperationOutput(XMLStreamReader reader, EditableWSDLOperation operation) {
  String msg = ParserUtil.getAttribute(reader, "message");
  QName msgName = ParserUtil.getQName(reader, msg);
  String name = ParserUtil.getAttribute(reader, "name");
  EditableWSDLOutput output = new WSDLOutputImpl(reader,name, msgName, operation);
  operation.setOutput(output);
  extensionFacade.portTypeOperationOutputAttributes(output, reader);
  extensionFacade.portTypeOperationOutput(operation, reader);
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    extensionFacade.portTypeOperationOutputElements(output, reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private void parsePortTypeOperationInput(XMLStreamReader reader, EditableWSDLOperation operation) {
  String msg = ParserUtil.getMandatoryNonEmptyAttribute(reader, "message");
  QName msgName = ParserUtil.getQName(reader, msg);
  String name = ParserUtil.getAttribute(reader, "name");
  EditableWSDLInput input = new WSDLInputImpl(reader, name, msgName, operation);
  operation.setInput(input);
  extensionFacade.portTypeOperationInputAttributes(input, reader);
  extensionFacade.portTypeOperationInput(operation, reader);
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    extensionFacade.portTypeOperationInputElements(input, reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/jaxws-rt

private void parsePortTypeOperationFault(XMLStreamReader reader, EditableWSDLOperation operation) {
  String msg = ParserUtil.getMandatoryNonEmptyAttribute(reader, "message");
  QName msgName = ParserUtil.getQName(reader, msg);
  String name = ParserUtil.getMandatoryNonEmptyAttribute(reader, "name");
  EditableWSDLFault fault = new WSDLFaultImpl(reader,name, msgName, operation);
  operation.addFault(fault);
  extensionFacade.portTypeOperationFaultAttributes(fault, reader);
  extensionFacade.portTypeOperationFault(operation, reader);
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    extensionFacade.portTypeOperationFaultElements(fault, reader);
  }
}

代码示例来源:origin: com.sun.xml.ws/rt

private void parsePortTypeOperationFault(XMLStreamReader reader, EditableWSDLOperation operation) {
  String msg = ParserUtil.getMandatoryNonEmptyAttribute(reader, "message");
  QName msgName = ParserUtil.getQName(reader, msg);
  String name = ParserUtil.getMandatoryNonEmptyAttribute(reader, "name");
  EditableWSDLFault fault = new WSDLFaultImpl(reader,name, msgName, operation);
  operation.addFault(fault);
  extensionFacade.portTypeOperationFaultAttributes(fault, reader);
  extensionFacade.portTypeOperationFault(operation, reader);
  while (XMLStreamReaderUtil.nextElementContent(reader) != XMLStreamConstants.END_ELEMENT) {
    extensionFacade.portTypeOperationFaultElements(fault, reader);
  }
}

26 4 0