AppCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ECardDataFacadeCommon.h
Go to the documentation of this file.
1 #ifndef ECARDDATAFACADECOMMON_H
2 #define ECARDDATAFACADECOMMON_H
3 
4 #include <string>
5 #include <set>
6 
7 #include "core/common/eplatform.h"
8 #include "appcore/cardfacade/ECardFacadeDefines.h"
9 
10 namespace EM
11 {
12  namespace PT
13  {
14  class EDataCollection;
15  class EAplRequest;
16  }
17 
18  namespace CardFacade
19  {
20  class ECardDataStorage;
22  {
23  public:
27  ECardDataFacadeCommon( ECardDataStorage *cardDataStorage );
28 
29 
33  virtual ~ECardDataFacadeCommon( );
34 
35 
41 
42 
49  bool GetLogicalCardNumber( unsigned long &logicalCardNumber, const signed char index = -1 ) const;
50 
51 
58  bool GetLogicalCardNumber( std::string &logicalCardNumber, const signed char index = -1 ) const;
59 
65  bool GetCardNumber( unsigned long &cardNumber ) const;
66 
67 
73  bool SetCardNumber( const unsigned long cardNumber ) const;
74 
75 
81  bool GetCardValidityEnd( unsigned long &cardValidityEnd ) const;
82 
83 
89  bool SetCardValidityEnd( const unsigned long cardValidityEnd ) const;
90 
91 
99  bool GetCardAdditionalDiscountValidity( unsigned long &additionalDiscountValidity, const signed char index = -1 ) const;
100 
101 
109  bool SetCardAdditionalDiscountValidity( const unsigned long additionalDiscountValidity, const signed char index = -1 ) const;
110 
111 
122  bool GetCardRegionCode( unsigned long &regionCode ) const;
123 
124 
137  bool GetCardCityCode( unsigned long &cityCode ) const;
138 
144  bool SetCardRegionCode( const unsigned long regionCode ) const;
145 
154  bool IsDiscountCouponValid( bool &isDiscountCouponValid, const signed char couponIndex ) const;
155 
162  bool GetNumberOfDiscountCoupons( unsigned long &numberOfCoupons ) const;
163 
172  bool GetDiscountCouponValidityEnd( unsigned long &couponValidityEnd, const signed char couponIndex ) const;
173 
182  bool SetDiscountCouponValidityEnd( const unsigned long couponValidityEnd, const signed char couponIndex ) const;
183 
192  bool GetDiscountCouponValidityStart(unsigned long &couponValidityStart, const signed char couponIndex ) const;
193 
202  bool GetDiscountCouponRegionCode( unsigned long &couponRegionCode, const signed char couponIndex ) const;
203 
212  bool GetDiscountCouponType(unsigned long &couponType, const signed char couponIndex ) const;
213 
220  bool GetCustomerProfilesCount( unsigned char &customerProfilesCount ) const;
221 
233  bool GetCustomerProfileValidityEnd( unsigned long &customerProfileValidityEnd, const unsigned char customerProfileIndex = 0, const signed char index = -1 ) const;
234 
242  bool SetCustomerProfileValidityEnd( const unsigned long customerProfileValidityEnd, const unsigned char customerProfileIndex = 0, const signed char index = -1 ) const;
243 
251  bool GetCustomerProfileValidityStart( unsigned long &customerProfileValidityStart, const unsigned char customerProfileIndex = 0, const signed char index = -1 ) const;
252 
259  bool SetCustomerProfileValidityStart( const unsigned long customerProfileValidityStart, const unsigned char customerProfileIndex = 0, const signed char index = -1 ) const;
260 
268  bool GetCardTypeAndSubType( unsigned short &cardType, unsigned short &cardSubType, ECardFacadeDefines::CardTypeStandard &cardStandard, const unsigned char customerProfileIndex, const signed char index = -1 ) const;
269 
270 
277  bool SetCardTypeAndSubType( const unsigned short cardType, const unsigned short cardSubType, const unsigned char customerProfileIndex, const signed char index = -1 ) const;
278 
279 
290  bool GetFareProviderNumber( unsigned short &fareProviderNumber, const signed char fareProviderIndex = -1 ) const;
291 
299  bool SetFareProviderNumber(const unsigned short providerNumber , const signed char fareProviderIndex = -1 ) const;
300 
306  bool GetCardPublisherNumber( unsigned short &cardPublisherNumber ) const;
307 
313  bool SetCardPublisherNumber( const unsigned short cardPublisherNumber ) const;
314 
321  bool GetNetworkCode( unsigned short &networkCodeInBCD ) const;
322 
329  bool SetNetworkCode( const unsigned short networkCodeInBCD ) const;
330 
337  bool GetCountryCode( unsigned short &countryCodeInBCD ) const;
338 
345  bool SetCountryCode( const unsigned short countryCodeInBCD ) const;
346 
352  bool GetAppExpireDate( unsigned long &appExpireDate ) const;
353 
359  bool SetAppExpireDate( const unsigned long appExpireDate ) const;
360 
366  bool GetAppIssuerType( unsigned short &appIssuerType ) const;
367 
373  bool SetAppIssuerType( const unsigned short appIssuerType ) const;
374 
381  DEPRECATED( bool GetSaleDate( unsigned long &saleDate, const signed char index = -1 ) const );
382 
383 
390  DEPRECATED( bool SetSaleDate( const unsigned long saleDate, const signed char index = -1 ) const );
391 
392 
400  bool IsCardBlocked( bool &cardBlocked, const signed char index = -1 ) const;
401 
410  bool SetCardBlocked( const bool blocked, const signed char index = -1 ) const;
411 
412 
419  bool IsCardSold( bool &cardSold, const signed char index = -1 ) const;
420 
428  bool SetCardSold( const bool sold, const signed char index = -1 ) const;
429 
435  bool GetUID( std::string &uid ) const;
436 
442  bool GetRawUID( unsigned char *&uid ) const;
443 
449  bool IsServiceCard( bool &serviceCard ) const;
450 
457  bool SetServiceCard( const bool serviceCard ) const;
458 
464  bool GetBornNumber( unsigned long &bornNumber ) const;
465 
471  bool SetBornNumber( const unsigned long bornNumber ) const;
472 
480  bool GetCardOwnerName( char *ownerName, unsigned short &nameLength, ECardFacadeDefines::TextEncoding &encoding ) const;
481 
488  bool SetCardOwnerName( const char *ownerName, const unsigned short nameLength ) const;
489 
497  bool GetCardOwnerSurname( char *ownerSurname, unsigned short &surnameLength, ECardFacadeDefines::TextEncoding &encoding ) const;
498 
505  bool SetCardOwnerSurname( const char *ownerSurname, const unsigned short surnameLength ) const;
506 
512  bool GetEventCount( unsigned long &eventCount ) const;
513 
521  bool GetCommonDataCount( unsigned char &commonDataCount ) const;
522 
531  bool GetCardPublisherVersion( unsigned char &publisherVersion );
532 
541  bool SetCardPublisherVersion( unsigned char publisherVersion );
542 
549  bool IsTransportSectionValid( bool &tranportSectionValid, const signed char index = -1 ) const;
550 
556  bool GetDailyCappingDate( unsigned long &dailyCappingDate );
557 
563  bool SetDailyCappingDate( unsigned long dailyCappingDate );
564 
570  bool GetDailyCappingSum( unsigned short &dailyCappingSum );
571 
577  bool SetDailyCappingSum( unsigned short dailyCappingSum );
578 
584  bool GetWeeklyCappingDate( unsigned long &weeklyCappingDate );
585 
591  bool SetWeeklyCappingDate( unsigned long weeklyCappingDate );
592 
598  bool GetWeeklyCappingSum( unsigned short &weeklyCappingSum );
599 
605  bool SetWeeklyCappingSum( unsigned short weeklyCappingSum );
606 
612  bool GetCappingProvider( unsigned short &cappingProvider );
613 
619  bool SetCappingProvider( unsigned short cappingProvider );
620 
626  bool GetCappingProviderType( ECardFacadeDefines::CappingProviderType &cappingProviderType );
627 
633  bool SetCappingProviderType( ECardFacadeDefines::CappingProviderType cappingProviderType );
634 
638  void Clear();
639 
644  bool IsModifiedData() const;
645 
651  bool PrepareWriteRequest( EM::PT::EDataCollection *writeRequest ) const;
652 
658  bool AddDataToWriteRequest( EM::PT::EDataCollection *writeRequest ) const;
659 
665  bool AddDataTypeToReadRequest(PT::EAplRequest *readRequest[] , const unsigned short dataTypesOperation) const;
666 
673  bool IsCommonDataFeatureEnabled( const ECardFacadeDefines::CommonDataFeatures feature, bool &enabled ) const;
674 
681  bool IsCardFeatureEnabled( const ECardFacadeDefines::CommonCardFeatures feature, bool &enabled ) const;
682 
689  bool IsDataValid( bool &validData, const signed char index = -1 );
690 
691  unsigned short GetRequiredDataReadOperation( const unsigned short dataTypesOperation ) const;
692 
693  private:
695 
696  class DataClass;
697  DataClass *d;
698 
700  };
701  }
702 }
703 
704 #endif // ECARDDATAFACADECOMMON_H
CappingProviderType
Definition: ECardFacadeDefines.h:279
ReturnValues
Definition: ECardFacadeDefines.h:144
EEventTripTicketPr __EDATAPTR d
Definition: EEventTripTicket.h:96
Definition: ECardDataFacadeCommon.h:21
CommonCardFeatures
Definition: ECardFacadeDefines.h:78
TextEncoding
Definition: ECardFacadeDefines.h:216
__ECLASS DataClass
Definition: EEventUpdateCustomerData.h:35
card data storage, who fill if card readed
Definition: ECardDataStorage.h:59
#define DLL_API
Definition: ECardFacadeDefines.h:8
SYSTEM INCLUDES.
Definition: CardFacadeManagerXML.h:6
#define DEPRECATED(func)
Definition: stdafx.h:77
CardTypeStandard
Definition: ECardFacadeDefines.h:247
CommonDataFeatures
Definition: ECardFacadeDefines.h:134
void Init(__ESTRING path)