⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wcservice.java

📁 电子地图服务器,搭建自己的地图服务
💻 JAVA
字号:
/* Copyright (c) 2001 - 2007 TOPP - www.openplans.org.  All rights reserved.
 * This code is licensed under the GPL 2.0 license, availible at the root
 * application directory.
 */
package org.vfny.geoserver.wcs.servlets;

import org.vfny.geoserver.ExceptionHandler;
import org.vfny.geoserver.global.WCS;
import org.vfny.geoserver.servlets.AbstractService;
import org.vfny.geoserver.wcs.WcsExceptionHandler;
import javax.servlet.http.HttpServletRequest;


/**
 * Base servlet for all Web Coverage Server requests.
 *
 * <p>
 * Subclasses should supply the handler, request and response mapping for the
 * service they implement.
 * </p>
 *
 * @author $Author: Alessio Fabiani (alessio.fabiani@gmail.com) $ (last modification)
 * @author $Author: Simone Giannecchini (simboss1@gmail.com) $ (last modification)
 * @version $Id: WCService.java 6326 2007-03-15 18:36:40Z jdeolive $
 */
abstract public class WCService extends AbstractService {
    /**
         * Constructor for WCS service.
         *
         * @param request The service request being made (GetCaps,GetCoverage,...)
         * @param wcs The WCS service reference.
         */
    public WCService(String request, WCS wcs) {
        super("WCS", request, wcs);
    }

    /**
     * @return The wcs service ref.
     */
    public WCS getWCS() {
        return (WCS) getServiceRef();
    }

    /**
     * Sets the wcs service ref.
     * @param wcs
     */
    public void setWCS(WCS wcs) {
        setServiceRef(wcs);
    }

    /**
     * a Web Coverage ServiceConfig exception handler
     *
     * @return an instance of WcsExceptionHandler
     */
    protected ExceptionHandler getExceptionHandler() {
        return WcsExceptionHandler.getInstance();
    }

    protected boolean isServiceEnabled(HttpServletRequest req) {
        return getWCS().isEnabled();
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -