tariffclass-gw.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.20 $
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 _TARIFFCLASSGW_H_
00031 #define _TARIFFCLASSGW_H_
00032 
00033 // *********************************************************************
00034 // included header files
00035 // + standard includes
00036 
00037 // + local headers
00038 #include "tariffclass.h"
00039 
00040 // *********************************************************************
00041 // class declarations
00042 namespace OSB_DB {
00043     class Session;
00044 }
00045 
00046 // ************************************************************************
00047 // namespace extensions
00048 namespace OSB_DB {
00049 
00050 // *********************************************************************
00051 // class definitions
00052 
00053     // *****************************************************************
00054     // struct TariffClassGw
00058     struct TariffClassGw {
00062         friend class OSB_LIB::TariffClass;
00063 
00072         long fetch(
00073             const Session&                session,
00074                   OSB_LIB::TariffClasses& tcs
00075         );
00076 
00089         bool fetch(
00090             const Session&              session,
00091                   OSB_LIB::TariffClass& tc
00092         );
00093 
00094     private:
00111         bool insTariffClass(
00112             const Session&              session,
00113                   OSB_LIB::TariffClass& tc
00114         );
00115 
00132         bool delTariffClass(
00133             const Session&              session,
00134                   OSB_LIB::TariffClass& tc
00135         );
00136 
00152         bool updTariffClass(
00153             const Session&              session,
00154                   OSB_LIB::TariffClass& tc
00155         );
00156 
00170         OSB_LIB::ObjectStatus checkObjVs(
00171             const Session&              session,
00172             const OSB_LIB::TariffClass& tc
00173         );
00174     };
00175 
00176     // *****************************************************************
00177     // struct TcSystemGw
00181     struct TcSystemGw {
00186         friend class OSB_LIB::TcSystem;
00187 
00198         long fetch(
00199             const Session&            session,
00200                   OSB_LIB::TcSystems& tcses
00201         );
00202 
00216         bool fetch(
00217             const Session&           session,
00218                   OSB_LIB::TcSystem& tcs
00219         );
00220 
00235         bool insTcSystem(
00236             const Session&           session,
00237                   OSB_LIB::TcSystem& tcs
00238         );
00239 
00254         bool delTcSystem(
00255             const Session&           session,
00256                   OSB_LIB::TcSystem& tcs
00257         );
00258 
00274         bool updTcSystem(
00275             const Session&           session,
00276                   OSB_LIB::TcSystem& tcs
00277         );
00278 
00293         OSB_LIB::ObjectStatus checkObjVs(
00294             const Session&           session,
00295             const OSB_LIB::TcSystem& tcs
00296         );
00297     };
00298 
00299     // *****************************************************************
00300     // struct TcsVersionGw
00304     struct TcsVersionGw {
00309         friend class OSB_LIB::TcsVersion;
00310 
00326         bool fetch(
00327             const Session&             session,
00328                   OSB_LIB::TcsVersion& tcsVs
00329         );
00330 
00340         long fetch(
00341             const Session&              session,
00342                   OSB_LIB::TcsVersions& dest
00343         );
00344 
00345     private:
00365         bool insTcsVersion(
00366             const Session&             session,
00367                   OSB_LIB::TcsVersion& tcsVs
00368         );
00369 
00392         bool delTcsVersion(
00393             const Session&             session,
00394                   OSB_LIB::TcsVersion& tcsVs
00395         );
00396 
00415         bool updTcsVersion(
00416             const Session&             session,
00417                   OSB_LIB::TcsVersion& tcsVs
00418         );
00419 
00433         OSB_LIB::ObjectStatus checkObjVs(
00434             const Session&             session,
00435             const OSB_LIB::TcsVersion& tcsVs
00436         );
00437 
00452         OSB_LIB::CfgStatus getStatus(
00453             const Session&                  session,
00454             const OSB_LIB::TcsVersion::Oid& oid
00455         ) const;
00456 
00467         bool isReleasedInFuture(
00468             const Session&                  session,
00469             const OSB_LIB::TcsVersion::Oid& oid
00470         ) const;
00471 
00482         bool isTcSystemUsedByReleasedTsVersion(
00483             const Session&                session,
00484             const OSB_LIB::TcSystem::Oid& oid
00485         ) const;
00486 
00497         bool isTcSystemUsedByFreezedTsVersion(
00498             const Session&                session,
00499             const OSB_LIB::TcSystem::Oid& oid
00500         ) const;
00501 
00512         OSB_LIB::DateTime nextReleasedVersion(
00513             const Session&                  session,
00514             const OSB_LIB::TcsVersion::Oid& oid
00515         ) const;
00516 
00526         bool hasOtherReleasedTcsVersion(
00527             const Session&                  session,
00528             const OSB_LIB::TcsVersion::Oid& oid
00529         );
00530 
00541         bool findReplacementFreezedTcsVersion(
00542             const Session&                  session,
00543             const OSB_LIB::TcsVersion::Oid& oid
00544         ) const;
00545 
00558         bool uniqueReleaseTs(
00559             const Session&                session,
00560             const OSB_LIB::TcSystem::Oid& oid,
00561             const OSB_LIB::DateTime&      ts
00562         ) const;
00563 
00572         bool updStatus(
00573             const Session&             session,
00574                   OSB_LIB::TcsVersion& tcsVs
00575         );
00576     };
00577 
00578 // *********************************************************************
00579 // inline definitions
00580 
00581 }                                       // namespace OSB_DB
00582 #endif                                  // #ifndef _TARIFFCLASSGW_H_

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