BaseTypeFactory.h

Go to the documentation of this file.
00001 
00002 // -*- mode: c++; c-basic-offset:4 -*-
00003 
00004 // This file is part of libdap, A C++ implementation of the OPeNDAP Data
00005 // Access Protocol.
00006 
00007 // Copyright (c) 2005 OPeNDAP, Inc.
00008 // Author: James Gallagher <jgallagher@opendap.org>
00009 //
00010 // This library is free software; you can redistribute it and/or
00011 // modify it under the terms of the GNU Lesser General Public
00012 // License as published by the Free Software Foundation; either
00013 // version 2.1 of the License, or (at your option) any later version.
00014 //
00015 // This library is distributed in the hope that it will be useful,
00016 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00017 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00018 // Lesser General Public License for more details.
00019 //
00020 // You should have received a copy of the GNU Lesser General Public
00021 // License along with this library; if not, write to the Free Software
00022 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00023 //
00024 // You can contact OPeNDAP, Inc. at PO Box 112, Saunderstown, RI. 02874-0112.
00025 
00026 #ifndef base_type_factory_h
00027 #define base_type_factory_h
00028 
00029 #include <string>
00030 
00031 // Class declarations; Make sure to include the corresponding headers in the
00032 // implementation file.
00033 
00034 class Byte;
00035 class Int16;
00036 class UInt16;
00037 class Int32;
00038 class UInt32;
00039 class Float32;
00040 class Float64;
00041 class Str;
00042 class Url;
00043 class Array;
00044 class Structure;
00045 class Sequence;
00046 class Grid;
00047 class BaseType;
00048 
00074 class BaseTypeFactory
00075 {
00076 public:
00077     BaseTypeFactory()
00078     {}
00079     virtual ~BaseTypeFactory()
00080     {}
00081 
00082     virtual Byte *NewByte(const string &n = "") const;
00083     virtual Int16 *NewInt16(const string &n = "") const;
00084     virtual UInt16 *NewUInt16(const string &n = "") const;
00085     virtual Int32 *NewInt32(const string &n = "") const;
00086     virtual UInt32 *NewUInt32(const string &n = "") const;
00087     virtual Float32 *NewFloat32(const string &n = "") const;
00088     virtual Float64 *NewFloat64(const string &n = "") const;
00089 
00090     virtual Str *NewStr(const string &n = "") const;
00091     virtual Url *NewUrl(const string &n = "") const;
00092 
00093     virtual Array *NewArray(const string &n = "", BaseType *v = 0) const;
00094     virtual Structure *NewStructure(const string &n = "") const;
00095     virtual Sequence *NewSequence(const string &n = "") const;
00096     virtual Grid *NewGrid(const string &n = "") const;
00097 };
00098 
00099 #endif // base_type_factory_h

Generated on Wed Jun 27 12:56:38 2007 for libdap++ by  doxygen 1.4.7