gpt4 book ai didi

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

转载 作者:知者 更新时间:2024-03-21 17:33:05 24 4
gpt4 key购买 nike

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

WFSGetFeatureOutputFormat.canHandle介绍

[英]Ensures that the operation being executed is a GetFeature operation.

Subclasses may implement
[中]确保正在执行的操作是GetFeature操作。
子类可以实现

代码示例

代码示例来源:origin: org.geoserver.extension/ogr

@Override
public boolean canHandle(Operation operation) {
  // we can't handle anything if the ogr2ogr configuration failed
  if(formats.size() == 0) {
    return false;
  } else {
    return super.canHandle(operation);
  }
}

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

@Override
public boolean canHandle(Operation operation) {
  // we can't handle anything if the ogr2ogr configuration failed
  if (formats.size() == 0) {
    return false;
  } else {
    return super.canHandle(operation);
  }
}

代码示例来源:origin: org.geoserver/xslt

@Override
public boolean canHandle(Operation operation) {
  // if we don't have formats configured, we cannot respond
  if(formats.isEmpty()) {
    System.out.println("Empty formats");
    return false;
  }
  
  if(!super.canHandle(operation)) {
    return false;
  }
  
  // check the format matches, the Dispatcher just does a case insensitive match,
  // but WFS is supposed to be case sensitive and so is the XSLT code
  Request request = Dispatcher.REQUEST.get();
  if(request != null && (request.getOutputFormat() == null || !formats.containsKey(request.getOutputFormat()))) {
    System.out.println("Formats are: " + formats);
    return false;
  } else {
    return true;
  }
}

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