org.apache.ws.commons.schema.XmlSchemaObjectTable.getItem()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(4.0k)|赞(0)|评价(0)|浏览(164)

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

XmlSchemaObjectTable.getItem介绍

暂无

代码示例

代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema

  1. public XmlSchemaElement getElementByName(QName name) {
  2. return (XmlSchemaElement)elements.getItem(name);
  3. }

代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema

  1. public XmlSchemaType getTypeByName(QName name) {
  2. return (XmlSchemaType)schemaTypes.getItem(name);
  3. }

代码示例来源:origin: com.legsem.legstar/legstar-xsd2cob

  1. /**
  2. * Get name for item from another schema.
  3. *
  4. * @param table the other schema table
  5. * @param xsdObject the object for which we seek a name
  6. * @return the name
  7. */
  8. protected static QName getName(final XmlSchemaObjectTable table,
  9. final XmlSchemaObject xsdObject) {
  10. for (Iterator < ? > it = table.getNames(); it.hasNext();) {
  11. QName name = (QName) it.next();
  12. if (xsdObject == table.getItem(name)) {
  13. return name;
  14. }
  15. }
  16. return null;
  17. }

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. } else {
  2. XmlSchemaAttribute attribute = (XmlSchemaAttribute) attributes
  3. .getItem(name);
  4. if (deep) {
  5. if (attribute == null) {

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. XmlSchemaType type = (XmlSchemaType) schemaTypes.getItem(name);

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. } else {
  2. XmlSchemaElement element = (XmlSchemaElement) elements
  3. .getItem(name);
  4. if (deep) {
  5. if (element == null) {

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. } else {
  2. XmlSchemaAttribute attribute = (XmlSchemaAttribute) attributes
  3. .getItem(name);
  4. if (deep) {
  5. if (attribute == null) {

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. } else {
  2. XmlSchemaElement element = (XmlSchemaElement) elements
  3. .getItem(name);
  4. if (deep) {
  5. if (element == null) {

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. XmlSchemaType type = (XmlSchemaType) schemaTypes.getItem(name);

代码示例来源:origin: org.apache.woden/woden-impl-commons

  1. ed.setSystem(typeSystemURI);
  2. ed.setContentModel(Constants.API_APACHE_WS_XS);
  3. ed.setContent(elementTable.getItem(xseQN));
  4. fDesc.addElementDeclaration(ed);

代码示例来源:origin: org.apache.woden/woden-impl-commons

  1. td.setSystem(typeSystemURI);
  2. td.setContentModel(Constants.API_APACHE_WS_XS);
  3. td.setContent(typeTable.getItem(xstQN));
  4. fDesc.addTypeDefinition(td);

代码示例来源:origin: com.legsem.legstar/legstar-xsd2cob

  1. /**
  2. * Take all elements from a collection and process them.
  3. *
  4. * @param items the parent collection
  5. * @param level the current level in the elements hierarchy.
  6. * @throws XsdMappingException if processing fails
  7. */
  8. protected void processCollectionElements(
  9. final XmlSchemaObjectCollection items, final int level)
  10. throws XsdMappingException {
  11. /* Process each element in the collection */
  12. for (int i = 0; i < items.getCount(); i++) {
  13. XmlSchemaObject element = items.getItem(i);
  14. if (element instanceof XmlSchemaElement) {
  15. processElement((XmlSchemaElement) element, level);
  16. } else if (element instanceof XmlSchemaGroupRef) {
  17. /* This is a reference to a group so we fetch the group */
  18. XmlSchemaGroupRef groupRef = (XmlSchemaGroupRef) element;
  19. XmlSchemaGroup group = (XmlSchemaGroup) _schema.getGroups()
  20. .getItem(groupRef.getRefName());
  21. processParticle(group.getName(), group.getParticle(), level);
  22. }
  23. }
  24. }

代码示例来源:origin: com.legsem.legstar/legstar-jaxbgen

  1. /**
  2. * Take all elements from a collection and process them.
  3. *
  4. * @param schema the XML Schema
  5. * @param jaxbNamespace the JAXB namespace
  6. * @param jaxbNamespacePrefix the JAXB namespace prefix
  7. * @param items the parent collection
  8. */
  9. protected void processCollectionElements(final XmlSchema schema,
  10. final String jaxbNamespace, final String jaxbNamespacePrefix,
  11. final XmlSchemaObjectCollection items) {
  12. for (int i = 0; i < items.getCount(); i++) {
  13. XmlSchemaObject element = items.getItem(i);
  14. if (element instanceof XmlSchemaElement) {
  15. processElement(schema, jaxbNamespace, jaxbNamespacePrefix,
  16. (XmlSchemaElement) element);
  17. } else if (element instanceof XmlSchemaGroupRef) {
  18. XmlSchemaGroupRef groupRef = (XmlSchemaGroupRef) element;
  19. XmlSchemaGroup group = (XmlSchemaGroup) schema.getGroups()
  20. .getItem(groupRef.getRefName());
  21. processParticle(schema, jaxbNamespace, jaxbNamespacePrefix,
  22. group.getName(), group.getParticle());
  23. }
  24. }
  25. }

相关文章