• Classes
  • Modules
  • Namespaces
  • Files
  • Related Pages
  • File List
  • File Members

InMemoryXmlData.h

Go to the documentation of this file.
00001 #ifndef _INMEMORYXMLDATA_H
00002 #define _INMEMORYXMLDATA_H
00003 
00004 /*******************************************************************************
00005 *    ALMA - Atacama Large Millimiter Array
00006 *    (c) Associated Universities Inc., 2002 
00007 *    (c) European Southern Observatory, 2002
00008 *    Copyright by ESO (in the framework of the ALMA collaboration)
00009 *    and Cosylab 2002, All rights reserved
00010 *
00011 *    This library is free software; you can redistribute it and/or
00012 *    modify it under the terms of the GNU Lesser General Public
00013 *    License as published by the Free Software Foundation; either
00014 *    version 2.1 of the License, or (at your option) any later version.
00015 *
00016 *    This library is distributed in the hope that it will be useful,
00017 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
00018 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00019 *    Lesser General Public License for more details.
00020 *
00021 *    You should have received a copy of the GNU Lesser General Public
00022 *    License along with this library; if not, write to the Free Software
00023 *    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
00024 *
00025 * "@(#) $Id: InMemoryXmlData.h,v 1.6 2006/11/29 23:01:26 sharring Exp $"
00026 *
00027 * who       when      what
00028 * --------  --------  ----------------------------------------------
00029 * sharring  1/11/05  created
00030 */
00031 #ifndef __cplusplus
00032 #error This is a C++ include file and cannot be used from plain C
00033 #endif
00034 
00035 #include <xercesc/util/XercesDefs.hpp>
00036 #include <xercesc/util/XMLString.hpp>
00037 #include <string>
00038 #include <iostream>
00039 
00040 using std::cerr;
00041 using std::endl;
00042 using std::string;
00043 using XERCES_CPP_NAMESPACE_QUALIFIER XMLString;
00044 
00045 namespace Parameters 
00046 {
00047         //------------------------------------------------------------------------------
00048         //
00049         //  InMemoryXmlData   One of these objects will be set up for the parameter set file listed
00050         //             on the command line.  Once set, the data is unchanging.
00051         //------------------------------------------------------------------------------
00052         class InMemoryXmlData
00053         {
00054                 private:
00055                         string  id;
00056                         string  content;
00057 
00058                 public :
00059                         // -----------------------------------------------------------------------
00060                         //  Constructors and Destructor
00061                         // -----------------------------------------------------------------------
00062 
00068                         InMemoryXmlData(string identifier, string contents)
00069                         {
00070                                 content = contents;
00071                                 id = identifier;
00072                         }
00073 
00074                         ~InMemoryXmlData()
00075                         {
00076                         }
00077 
00078                         string getId() { return id;}
00079                         string getContent() { return content;}
00080                         const size_t getSize() { return (const size_t) content.length(); }
00081         };
00082 }
00083 #endif 

Generated on Thu Jan 12 2012 23:13:51 for ACS-10.0 C++ API by  doxygen 1.7.0