gpt4 book ai didi

org.geoserver.wfs.WFSGetFeatureOutputFormat.getCapabilitiesElementName()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-21 18:01:05 27 4
gpt4 key购买 nike

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

WFSGetFeatureOutputFormat.getCapabilitiesElementName介绍

[英]Capabilities output format string. Something that's a valid XML element name. This should be overriden in each outputformat subclass, and if it's not a warning will be issued.
[中]功能输出格式字符串。是一个有效的XML元素名。这应该在每个outputformat子类中被覆盖,如果不是,将发出警告。

代码示例

代码示例来源:origin: org.geoserver/gs-wfs

/**
 * Returns the list of output format names generated by this format, for inclusion in the WFS
 * 1.0 capabilities document as XML element names
 */
public List<String> getCapabilitiesElementNames() {
  String name = getCapabilitiesElementName();
  if (name == null) {
    return Collections.emptyList();
  } else {
    return Arrays.asList(name);
  }
}

代码示例来源:origin: org.geoserver/gs-wfs

@Test
public void testOutputFormats() throws Exception {
  Document doc = getAsDOM("wfs?service=WFS&request=getCapabilities&version=1.0.0");
  Element outputFormats = getFirstElementByTagName(doc, "ResultFormat");
  NodeList formats = outputFormats.getChildNodes();
  TreeSet s1 = new TreeSet();
  for (int i = 0; i < formats.getLength(); i++) {
    String format = formats.item(i).getNodeName();
    s1.add(format);
  }
  List extensions = GeoServerExtensions.extensions(WFSGetFeatureOutputFormat.class);
  TreeSet s2 = new TreeSet();
  for (Iterator e = extensions.iterator(); e.hasNext(); ) {
    WFSGetFeatureOutputFormat extension = (WFSGetFeatureOutputFormat) e.next();
    s2.add(extension.getCapabilitiesElementName());
  }
  assertEquals(s1, s2);
}

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com