SawData.cpp

00001 /***************************************************************************
00002  *   Copyright (C) 2005 by Nestor Aguirre                                  *
00003  *   nfaguirrec@unal.edu.co                                                *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  *                                                                         *
00010  *   This program is distributed in the hope that it will be useful,       *
00011  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00012  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
00013  *   GNU General Public License for more details.                          *
00014  *                                                                         *
00015  *   You should have received a copy of the GNU General Public License     *
00016  *   along with this program; if not, write to the                         *
00017  *   Free Software Foundation, Inc.,                                       *
00018  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
00019  ***************************************************************************/
00020 #include "SawData.h"
00021 
00028 SawData::SawData( SawComplex x, SawComplex y )
00029 :SawObject()
00030 {
00031         this->x = x ;
00032         this->y = y ;
00033 }
00034 
00040 SawData::SawData( const SawData& gppdata )
00041 :SawObject()
00042 {
00043         this->x = gppdata.getX() ;
00044         this->y = gppdata.getY() ;
00045 }
00046 
00051 SawData::~SawData(){
00052 }
00053 
00058 void SawData::setX( SawComplex x ){
00059         this->x = x ;
00060 }
00061 
00066 void SawData::setY( SawComplex y ){
00067         this->y = y ;
00068 }
00069 
00074 SawComplex SawData::getX() const{
00075         return x ;
00076 }
00077 
00082 SawComplex SawData::getY() const{
00083         return y ;
00084 }
00085 
00092 ostream& operator << ( ostream& os, const SawData& e )
00093 {
00094         os.precision( e.precisionOutputStream ) ;
00095         
00096         os << "[ " << e.getX() << " : " << e.getY() << " ]" ;
00097         
00098         return os ;
00099 }
00100 
00107 istream& operator >> ( istream& is, SawData& e )
00108 {
00109         SawComplex r, i ;
00110         is >> r ;
00111         is >> i ;
00112         e.setX( r ) ;
00113         e.setY( i ) ;
00114         
00115         return is ;
00116 }
00117 
00118 
00119 

Generado el Sun Jul 22 18:05:41 2007 para SAW por  doxygen 1.5.1