Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

customer.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  $RCSfile: customer.h,v $
00003                              -------------------
00004     cvs         : $Id: customer.h,v 1.9 2003/04/13 21:29:52 aquamaniac Exp $
00005     begin       : Sun Nov 18 2001
00006     copyright   : (C) 2001 by Martin Preuss
00007     email       : openhbci@aquamaniac.de
00008 
00009  ***************************************************************************
00010  *                                                                         *
00011  *   This library is free software; you can redistribute it and/or         *
00012  *   modify it under the terms of the GNU Lesser General Public            *
00013  *   License as published by the Free Software Foundation; either          *
00014  *   version 2.1 of the License, or (at your option) any later version.    *
00015  *                                                                         *
00016  *   This library is distributed in the hope that it will be useful,       *
00017  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00018  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU     *
00019  *   Lesser General Public License for more details.                       *
00020  *                                                                         *
00021  *   You should have received a copy of the GNU Lesser General Public      *
00022  *   License along with this library; if not, write to the Free Software   *
00023  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston,                 *
00024  *   MA  02111-1307  USA                                                   *
00025  *                                                                         *
00026  ***************************************************************************/
00027 
00028 
00029 #ifndef HBCICUSTOMER_H
00030 #define HBCICUSTOMER_H
00031 
00037 #ifdef __cplusplus
00038 #include <string>
00039 #include <list>
00040 using namespace std;
00041 #include <openhbci/pointer.h>
00042 namespace HBCI {
00043         class Customer;
00044 }
00045 /* list declaration necessary for C wrappers */
00046 typedef struct HBCI::Customer HBCI_Customer;
00047 typedef list<HBCI::Pointer<HBCI::Customer> > list_HBCI_Customer;
00048 typedef list<HBCI::Pointer<HBCI::Customer> >::const_iterator list_HBCI_Customer_iter;
00049 
00050 #else /* __cplusplus */
00051 typedef struct HBCI_Customer HBCI_Customer;
00052 typedef struct list_HBCI_Customer list_HBCI_Customer;
00053 typedef struct list_HBCI_Customer_iter list_HBCI_Customer_iter;
00054 #endif /* __cplusplus */
00055 
00056 #include <openhbci/user.h>
00057 
00058 #ifdef __cplusplus
00059 
00060 namespace HBCI {
00088 class DLLIMPORT Customer {
00089 private:
00090     Pointer<User> _user;
00091     string _custId;
00092     string _custName;
00093 
00094 public:
00105     Customer(Pointer<User> u,
00106              const string &id,
00107              const string &custName="");
00108 
00110     Customer(const Customer &cu);
00112     ~Customer();
00113 
00119     Pointer<User> user() const { return _user;};
00120 
00127     const string& custId() const { return _custId;};
00128 
00138     const string& custName() const { return _custName;};
00147     void setCustName(const string &n) { _custName = n; };
00148 
00152     /* bool operator==(const HBCICustomer &c) const; */
00153 };
00154 } /* namespace HBCI */
00155 
00156 #endif /* __cplusplus */
00157 
00158 #ifdef __cplusplus
00159 extern "C" {
00160 #endif
00161 
00168     extern const HBCI_User* HBCI_Customer_user(const HBCI_Customer *h);
00169 
00178     extern const char* HBCI_Customer_custId(const HBCI_Customer *h);
00179 
00190     extern const char* HBCI_Customer_custName(const HBCI_Customer *h);
00200     extern void HBCI_Customer_setCustName(HBCI_Customer *h, const char *n);
00212     extern void list_HBCI_Customer_delete(list_HBCI_Customer *l);
00213     extern int list_HBCI_Customer_size(const list_HBCI_Customer *l);
00214     extern void list_HBCI_Customer_iter_delete(list_HBCI_Customer_iter *l);
00215     extern list_HBCI_Customer_iter* 
00216     list_HBCI_Customer_begin(const list_HBCI_Customer *l);
00217     extern list_HBCI_Customer_iter* 
00218     list_HBCI_Customer_end(const list_HBCI_Customer *l);
00219     extern const HBCI_Customer* 
00220     list_HBCI_Customer_iter_get(const list_HBCI_Customer_iter *l);
00221     extern void
00222     list_HBCI_Customer_iter_next(list_HBCI_Customer_iter *l);
00223     extern int 
00224     list_HBCI_Customer_iter_equal(const list_HBCI_Customer_iter *l1, 
00225                                   const list_HBCI_Customer_iter *l2);
00227     typedef void *(*list_HBCI_Customer_cb) (const HBCI_Customer *customer, 
00228                                             void *user_data);
00240     extern void *list_HBCI_Customer_foreach (const list_HBCI_Customer *list, 
00241                                              list_HBCI_Customer_cb func,
00242                                              void *user_data);
00244 #ifdef __cplusplus
00245 } /* __cplusplus */
00246 #endif
00247 
00248 
00249 
00250 #endif
00251 
00252 
00253 
00254 

Generated on Mon Jun 23 13:41:07 2003 for openhbci by doxygen1.2.17