libdap
Updated for version 3.17.0
|
00001 // -*- mode: c++; c-basic-offset:4 -*- 00002 00003 // This file is part of libdap, A C++ implementation of the OPeNDAP Data 00004 // Access Protocol. 00005 00006 // Copyright (c) 2013 OPeNDAP, Inc. 00007 // Author: Nathan Potter <npotter@opendap.org> 00008 // 00009 // This library is free software; you can redistribute it and/or 00010 // modify it under the terms of the GNU Lesser General Public 00011 // License as published by the Free Software Foundation; either 00012 // version 2.1 of the License, or (at your option) any later version. 00013 // 00014 // This library is distributed in the hope that it will be useful, 00015 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00017 // Lesser General Public License for more details. 00018 // 00019 // You should have received a copy of the GNU Lesser General Public 00020 // License along with this library; if not, write to the Free Software 00021 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00022 // 00023 // You can contact OPeNDAP, Inc. at PO Box 112, Saunderstown, RI. 02874-0112. 00024 00025 /* 00026 * AbstractFunction.cc 00027 * 00028 * Created on: Feb 2, 2013 00029 * Author: ndp 00030 */ 00031 00032 #include "config.h" 00033 00034 #include "ServerFunction.h" 00035 00036 using namespace std; 00037 00038 namespace libdap { 00039 00040 ServerFunction::ServerFunction() : d_bool_func(0), d_btp_func(0), d_proj_func(0), d_d4_function(0) 00041 { 00042 setName("abstract_function"); 00043 setDescriptionString("This function does nothing."); 00044 setUsageString("You can't use this function"); 00045 setRole("http://services.opendap.org/dap4/server-side-function/null"); 00046 setDocUrl("http://docs.opendap.org/index.php/Server_Side_Processing_Functions"); 00047 } 00048 00049 ServerFunction::ServerFunction(string name, string version, string description, string usage, string doc_url, 00050 string role, bool_func f) : d_bool_func(0), d_btp_func(0), d_proj_func(0), d_d4_function(0) 00051 { 00052 setName(name); 00053 setVersion(version); 00054 setDescriptionString(description); 00055 setUsageString(usage); 00056 setRole(role); 00057 setDocUrl(doc_url); 00058 setFunction(f); 00059 } 00060 00061 ServerFunction::ServerFunction(string name, string version, string description, string usage, string doc_url, 00062 string role, btp_func f) : d_bool_func(0), d_btp_func(0), d_proj_func(0), d_d4_function(0) 00063 { 00064 setName(name); 00065 setVersion(version); 00066 setDescriptionString(description); 00067 setUsageString(usage); 00068 setRole(role); 00069 setDocUrl(doc_url); 00070 setFunction(f); 00071 00072 } 00073 00074 ServerFunction::ServerFunction(string name, string version, string description, string usage, string doc_url, 00075 string role, proj_func f) : d_bool_func(0), d_btp_func(0), d_proj_func(0), d_d4_function(0) 00076 { 00077 setName(name); 00078 setVersion(version); 00079 setDescriptionString(description); 00080 setUsageString(usage); 00081 setRole(role); 00082 setDocUrl(doc_url); 00083 setFunction(f); 00084 } 00085 00086 ServerFunction::ServerFunction(string name, string version, string description, string usage, string doc_url, 00087 string role, D4Function f) : d_bool_func(0), d_btp_func(0), d_proj_func(0), d_d4_function(0) 00088 { 00089 setName(name); 00090 setVersion(version); 00091 setDescriptionString(description); 00092 setUsageString(usage); 00093 setRole(role); 00094 setDocUrl(doc_url); 00095 setFunction(f); 00096 } 00097 00098 } /* namespace libdap */