001    //$HeadURL: svn+ssh://rbezema@svn.wald.intevation.org/deegree/base/tags/2.1/src/org/deegree/ogcwebservices/getcapabilities/OGCWebServiceCapabilities.java $
002    /*----------------    FILE HEADER  ------------------------------------------
003    
004     This file is part of deegree.
005     Copyright (C) 2001-2006 by:
006     EXSE, Department of Geography, University of Bonn
007     http://www.giub.uni-bonn.de/deegree/
008     lat/lon GmbH
009     http://www.lat-lon.de
010    
011     This library is free software; you can redistribute it and/or
012     modify it under the terms of the GNU Lesser General Public
013     License as published by the Free Software Foundation; either
014     version 2.1 of the License, or (at your option) any later version.
015    
016     This library is distributed in the hope that it will be useful,
017     but WITHOUT ANY WARRANTY; without even the implied warranty of
018     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
019     Lesser General Public License for more details.
020    
021     You should have received a copy of the GNU Lesser General Public
022     License along with this library; if not, write to the Free Software
023     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
024    
025     Contact:
026    
027     Andreas Poth
028     lat/lon GmbH
029     Aennchenstr. 19
030     53115 Bonn
031     Germany
032     E-Mail: poth@lat-lon.de
033    
034     Prof. Dr. Klaus Greve
035     Department of Geography
036     University of Bonn
037     Meckenheimer Allee 166
038     53115 Bonn
039     Germany
040     E-Mail: greve@giub.uni-bonn.de
041    
042     
043     ---------------------------------------------------------------------------*/
044    package org.deegree.ogcwebservices.getcapabilities;
045    
046    import org.deegree.framework.log.ILogger;
047    import org.deegree.framework.log.LoggerFactory;
048    import org.deegree.framework.xml.Marshallable;
049    import org.w3c.dom.Document;
050    
051    /**
052     * The purpose of the GetCapabilities operation is described in the Basic
053     * CapabilitiesService Elements section, above. In the particular case of a Web
054     * Map CapabilitiesService, the response of a GetCapabilities request is general
055     * information about the service itself and specific information about the
056     * available maps.
057     * 
058     * @author <a href="mailto:k.lupp@web.de">Katharina Lupp </a>
059     * @author <a href="mailto:tfr@users.sourceforge.net">Torsten Friebe </a>
060     * @version 2002-03-01, $Revision: 6259 $, $Date: 2007-03-20 10:15:15 +0100 (Di, 20 Mär 2007) $
061     * @since 1.0
062     */
063    
064    public abstract class OGCWebServiceCapabilities implements Marshallable {
065    
066        protected static final ILogger LOG = LoggerFactory.getLogger(OGCWebServiceCapabilities.class);
067    
068    
069        private CapabilitiesService service = null;
070        private String updateSequence = null;
071        private String version = null;
072    
073        /**
074         * constructor initializing the class with the OGCWebServiceCapabilities
075         */
076        public OGCWebServiceCapabilities(String version, String updateSequence,
077                CapabilitiesService service) {
078            setVersion(version);
079            setUpdateSequence(updateSequence);
080            setService(service);
081        }
082    
083        /**
084         * returns the version of the service
085         */
086        public String getVersion() {
087            return version;
088        }
089    
090        /**
091         * sets the version of the service
092         */
093        public void setVersion(String version) {
094            this.version = version;
095        }
096    
097        /**
098         * The UPDATESEQUENCE parameter is for maintaining cache consistency. Its
099         * value can be an integer, a timestamp in [ISO 8601:1988(E)] format , or
100         * any other number or string. The server may include an UpdateSequence
101         * value in its Capabilities XML. If present, this value should be increased
102         * when changes are made to the Capabilities (e.g., when new maps are added
103         * to the service). The server is the sole judge of lexical ordering
104         * sequence. The client may include this parameter in its GetCapabilities
105         * request.
106         */
107        public String getUpdateSequence() {
108            return updateSequence;
109        }
110    
111        /**
112         * sets the update sequence
113         */
114        public void setUpdateSequence(String updateSequence) {
115            this.updateSequence = updateSequence;
116        }
117    
118        /**
119         * this returns a general describtion of the service described by the
120         * Capabilities XML document.
121         */
122        public CapabilitiesService getService() {
123            return service;
124        }
125    
126        /**
127         * this sets a general describtion of the service described by the
128         * Capabilities XML document.
129         */
130        public void setService(CapabilitiesService service) {
131            this.service = service;
132        }
133    
134        /**
135         * Must be overridden by subclass. Replaces abstract method exportAsXML.
136         *  
137         */
138        public Document export() {
139            return null;
140        }
141    }/* ********************************************************************
142    Changes to this class. What the people have been up to:
143    $Log$
144    Revision 1.9  2006/07/12 14:46:16  poth
145    comment footer added
146    
147    ********************************************************************** */