numberanalyzer01.h

Go to the documentation of this file.
00001 // OSB library ********************************************* -*- C++ -*-
00006 /*
00007   AUTHOR(S): Tang Boon Leong (tbl)
00008 
00009   RCS information
00010    $Name: OSB_060808 $
00011    $Revision: 1.10 $
00012 
00013   License
00014    OSB rating and billing library for communication networks
00015    Copyright (C) 2004, 2005, 2006  OSB systems
00016 
00017    This file may be distributed and/or modify under the terms of the
00018    GNU General Public License (GPL) as published by the Free Software
00019    Foundation which is provided in the file LICENSE.GPL included in the
00020    packaging of this file.
00021 
00022    The file is distributed in the hope that it will be useful, but WITHOUT
00023    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00024    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00025    for more details.
00026 
00027    Holders of a OSB Commercial License may use this file under the terms
00028    and conditions of this commercial license.
00029  */
00030 #ifndef _NUMBERANALYZER01_H_
00031 #define _NUMBERANALYZER01_H_
00032 
00033 // *********************************************************************
00034 // included header files
00035 // + standard includes
00036 
00037 // + local headers
00038 #include "numberanalyzer.h"
00039 #include "nwaddress.h"
00040 
00041 // *********************************************************************
00042 // class declarations
00043 namespace OSB_DB {
00044     class NumberAnalyzer01Gw;
00045 }
00046 
00047 // ************************************************************************
00048 // namespace extensions
00049 namespace OSB_LIB {
00050 
00051 // *********************************************************************
00052 // class definitions
00053 
00054     // *****************************************************************
00055     // NumberAnalyzer01
00061     class NumberAnalyzer01 : public NumberAnalyzer {
00063         friend class OSB_DB::NumberAnalyzer01Gw;
00064     public:
00066         typedef OSB_LIB::NwAddress::Ton Ton;
00067 
00072         NumberAnalyzer01(const Oid& oid = Oid());
00073 
00075 
00076 
00086         virtual bool analyzeCalling(NwAddress& nwAddress) const;
00087 
00098         virtual bool analyzeCalled(NwAddress& nwAddress) const;
00100 
00102 
00103 
00112         const std::string& rmPrefix() const;
00113 
00123         const std::string& addPrefix() const;
00124 
00131         const NwAddress::Ton& ton() const;
00133 
00135 
00136 
00140         void setRmPrefix(const std::string& rmPrefix);
00141 
00146         void setAddPrefix(const std::string& addPrefix);
00147 
00152         void setTon(const NwAddress::Ton& ton);
00154 
00155     private:
00157 
00158 
00165         void rmPrefix(NwAddress& nwAddress) const;
00166 
00174         void addPrefix(NwAddress& nwAddress) const;
00176 
00178 
00179 
00186         virtual bool readSpecific(const OSB_DB::Session& session);
00187 
00192         virtual void insSpecific(const OSB_DB::Session& session);
00193 
00198         virtual void removeSpecific(const OSB_DB::Session& session);
00199 
00204         virtual void updSpecific(const OSB_DB::Session& session);
00206 
00208         virtual NumberAnalyzer* clone_() const;
00209 
00210     private:
00212         std::string    rmPrefix_;
00213 
00215         std::string    addPrefix_;
00216 
00218         NwAddress::Ton ton_;
00219     };
00220 
00221 // *********************************************************************
00222 // inline definitions
00223 
00224 }                                       // namespace OSB_LIB
00225 #endif                                  // #ifndef _NUMBERANALYZER01_H_

Generated on Sat Sep 2 14:06:33 2006 for OSB Library by  doxygen 1.4.7