FFData.hpp

Go to the documentation of this file.
00001 #pragma ident "$Id: FFData.hpp 3140 2012-06-18 15:03:02Z susancummins $"
00002 
00003 
00004 
00010 #ifndef GPSTK_FFDATA_HPP
00011 #define GPSTK_FFDATA_HPP
00012 
00013 //============================================================================
00014 //
00015 //  This file is part of GPSTk, the GPS Toolkit.
00016 //
00017 //  The GPSTk is free software; you can redistribute it and/or modify
00018 //  it under the terms of the GNU Lesser General Public License as published
00019 //  by the Free Software Foundation; either version 2.1 of the License, or
00020 //  any later version.
00021 //
00022 //  The GPSTk is distributed in the hope that it will be useful,
00023 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
00024 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00025 //  GNU Lesser General Public License for more details.
00026 //
00027 //  You should have received a copy of the GNU Lesser General Public
00028 //  License along with GPSTk; if not, write to the Free Software Foundation,
00029 //  Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
00030 //  
00031 //  Copyright 2004, The University of Texas at Austin
00032 //
00033 //============================================================================
00034 
00035 //============================================================================
00036 //
00037 //This software developed by Applied Research Laboratories at the University of
00038 //Texas at Austin, under contract to an agency or agencies within the U.S. 
00039 //Department of Defense. The U.S. Government retains all rights to use,
00040 //duplicate, distribute, disclose, or release this software. 
00041 //
00042 //Pursuant to DoD Directive 523024 
00043 //
00044 // DISTRIBUTION STATEMENT A: This software has been approved for public 
00045 //                           release, distribution is unlimited.
00046 //
00047 //=============================================================================
00048 
00049 
00050 
00051 
00052 
00053 
00054 #include <iostream>
00055 #include <typeinfo>
00056 
00057 #include "FFStreamError.hpp"
00058 #include "StringUtils.hpp"
00059 
00060 namespace gpstk
00061 {
00064 
00066    class FFStream;
00067 
00094    class FFData
00095    {
00096    public:
00098       virtual ~FFData(void) {};
00099 
00104       void putRecord(FFStream& s) const 
00105          throw(FFStreamError, gpstk::StringUtils::StringException);
00106 
00120       void getRecord(FFStream& s) 
00121          throw(FFStreamError, gpstk::StringUtils::StringException);
00122 
00127       virtual void dump(std::ostream& s) const {}
00128 
00133       virtual bool isHeader() const {return false;}
00138       virtual bool isData() const {return false;}
00139 
00149       friend std::ostream& operator<<(std::ostream& o, const FFData& f)
00150          throw(FFStreamError, gpstk::StringUtils::StringException);
00151 
00170       friend std::istream& operator>>(std::istream& i, FFData& f)
00171          throw(FFStreamError, gpstk::StringUtils::StringException);
00172 
00173       friend class FFStream;
00174 
00175    protected:
00177       virtual void reallyGetRecord(FFStream& s)
00178          throw(std::exception, gpstk::StringUtils::StringException, 
00179                gpstk::FFStreamError) = 0;
00180 
00182       virtual void reallyPutRecord(FFStream& s) const
00183          throw(std::exception, gpstk::StringUtils::StringException, 
00184                gpstk::FFStreamError) = 0;
00185    }; // class
00186 
00188 
00189 } // namespace
00190 
00191 #endif

Generated on Wed May 22 03:31:07 2013 for GPS ToolKit Software Library by  doxygen 1.3.9.1