System documentation of the GNU Image-Finding Tool

Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members

CRelevanceLevel.h

00001 /* -*- mode: c++ -*- 
00002 */
00003 /* 
00004 
00005     GIFT, a flexible content based image retrieval system.
00006     Copyright (C) 1998, 1999, 2000, 2001, 2002, CUI University of Geneva
00007 
00008      Copyright (C) 2003, 2004 Bayreuth University
00009       2005 Bamberg University
00010     This program is free software; you can redistribute it and/or modify
00011     it under the terms of the GNU General Public License as published by
00012     the Free Software Foundation; either version 2 of the License, or
00013     (at your option) any later version.
00014 
00015     This program 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
00018     GNU General Public License for more details.
00019 
00020     You should have received a copy of the GNU General Public License
00021     along with this program; if not, write to the Free Software
00022     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00023 
00024 */
00042 #ifndef _CRELEVANCELEVEL
00043 #define _CRELEVANCELEVEL
00044 #include "libMRML/include/uses-declarations.h"
00045 #include <iostream>
00046 #include <string>
00047 #include "libMRML/include/TID.h"
00048 #include <functional>
00049 
00060 class CRelevanceLevel{
00062   string mURL;
00064   double mRelevanceLevel;
00065 public:
00072   CRelevanceLevel();
00073   
00079   CRelevanceLevel(const string& inURL,
00080                   double inRelevanceLevel);
00081   
00087   CRelevanceLevel(const CRelevanceLevel& inElement);
00088   
00095   bool input(istream& inStream);
00096   
00102   bool output(ostream& outStream)const;
00103   
00109   bool outputHTML(ostream& outStream)const;
00110   
00112   
00118   string getURL()const;
00119   
00125   double getRelevanceLevel()const;
00126   
00132   void setRelevanceLevel(const double inRelevanceLevel);
00133   
00139   void adjustRelevanceLevel(const double inRelevanceLevel);
00140   
00146   void divideRelevanceLevelBy(const double inDivisor);
00148   string toXML()const;
00149 };
00150 
00156 bool operator<(const CRelevanceLevel& l,
00157                const CRelevanceLevel& t);
00158 
00160 class CSortByURL_RL:public binary_function<CRelevanceLevel,CRelevanceLevel,bool>{
00161  public:
00163   bool operator()(const CRelevanceLevel& l,
00164                   const CRelevanceLevel& t)const;
00165 };
00166 
00167 
00168 #endif

Need for discussion? Want to contribute? Contact
help-gift@gnu.org Generated using Doxygen