Project

General

Profile

Specification » History » Version 3

Soh Keong, 10/20/2020 01:37 PM

1 1 Soh Keong
h1. Specification
2
3
h1. Programming Guide
4
5
h2. Resources
6
7
h3. SCM
8
9
see [[wiki#SCM]]
10
11
h3. Jar File Download
12
13
"Jar":/redmine/attachments/download/481/bcard-infinite-2.2.jar
14
"Lib":/redmine/attachments/download/482/json_lib.zip
15
"Properties":/redmine/attachments/download/480/service.properties
16
17
h3. properties file
18
19
* *service.properties*
20
21
# *ws.key*          - Provided by bInfinite
22
# *ws.company.code* - Provided by bInfinite
23
# *ws.branch.code*  - Provided by bInfinite
24
# *ws.post.id*      - Provided by bInfinite
25
26
h2. Methods
27
28
h3. Common Instance
29
30
<pre>
31
com.cosway.bcard.service.BcardService service = new com.cosway.bcard.service.BcardService();
32
</pre>
33
34
h3. Point Inquiry
35
36
<pre>
37
com.cosway.bcard.bean.PointResultBean resultBean = service.pointInquiry(CardBean cardBean);
38
</pre>
39
40
* *com.cosway.bcard.bean.CardBean*
41
> * *bcardNo*   - bInfinite card number
42
> * *password*  - bInfinite card's password
43
44
* *com.cosway.bcard.bean.PointResultBean*
45
> * *errorCode*       - String
46
> * *errorMessage*    - String 
47
> * *bcardNo*         - String
48
> * *principalPoint*  - int
49
> * *tokenPoint*      - int
50
> * *mintoken*        - int
51
> * *totalpoint*      - int
52
53
h3. Check Card
54
55
<pre>
56 2 Soh Keong
com.cosway.bcard.bean.CheckCardResultBean resultBean = service.checkCard(String cardNumber);
57 1 Soh Keong
</pre>
58
59
* *com.cosway.bcard.bean.CheckCardResultBean*
60
> * *errorCode*       - String
61
> * *errorMessage*    - String 
62
> * *bcardNo*         - String
63
> * *status*          - String
64 2 Soh Keong
65 3 Soh Keong
h3. Redemption | Void Redemption
66 2 Soh Keong
67 1 Soh Keong
<pre>
68 3 Soh Keong
com.cosway.bcard.bean.RedemptionResultBean resultBean = service.redemption(RedemptionBean redempBean);
69
com.cosway.bcard.bean.RedemptionResultBean resultBean = service.voidRedemption(RedemptionBean redempBean);
70 2 Soh Keong
</pre>
71
72
* *com.cosway.bcard.bean.RedemptionBean*
73
> * *bcardNo*       - String
74
> * *password*      - String
75 1 Soh Keong
> * *trxDate*       - Date
76 2 Soh Keong
> * *point*         - int
77
78 3 Soh Keong
* *com.cosway.bcard.bean.RedemptionResultBean*
79 2 Soh Keong
> * *errorCode*       - String
80
> * *errorMessage*    - String 
81
> * *bcardNo*         - String
82 1 Soh Keong
> * *redemptionId*    - String
83
> * *redemptionDate*  - Date
84
> * *balancePoint*    - int
85 3 Soh Keong
86
h3. Reward | Void Reward
87
88
<pre>
89
com.cosway.bcard.bean.RewardResultBean resultBean = service.reward(RewardBean redempBean);
90
com.cosway.bcard.bean.RewardResultBean resultBean = service.voidReward(RewardBean redempBean);
91
</pre>
92
93
* *com.cosway.bcard.bean.RewardBean*
94
> * *bcardNo*       - String
95
> * *orderId*       - String
96
> * *trxDate*       - Date
97
> * *totalAmount*   - double
98
> * *totalPoint*    - int
99
100
* *com.cosway.bcard.bean.RewardResultBean*
101
> * *errorCode*    - String
102
> * *errorMessage* - String 
103
> * *bcardNo*      - String
104
> * *rewardId*     - String
105
> * *rewardDate*   - Date
106
107
108
h3. Register Member
109
110
<pre>
111
com.cosway.bcard.bean.ResultBean resultBean = service.registerMember(RegistrationBean bean);
112
</pre>
113
114
* *com.cosway.bcard.bean.RegistrationBean*
115
> * *bcardNo*        - String (Mantadory)
116
> * *memberFullName* - String (Mantadory)
117
> * *memberIc*       - String (Mantadory)
118
> * *homeEmail*      - String (Mantadory)
119
> * *mobilePhone*    - String (Mantadory)
120
> * *memberTitle*    - String
121
> * *memberDOB*      - Date
122
> * *gender*         - String
123
> * *race*           - String
124
> * *nationality*    - String
125
> * *maritalStatus*  - String
126
> * *ownCar*         - boolean
127
> * *ownCreditCard*  - boolean
128
> * *homeAddress1*        - String
129
> * *homeAddress2*        - String
130
> * *homeAddress3*        - String
131
> * *homeCity*        - String
132
> * *homeState*        - String
133
> * *homeCountry*        - String
134
> * *homePostcode*        - String
135
> * *homePhone*        - String
136
> * *officeAddress1*        - String
137
> * *officeAddress2*        - String
138
> * *officeAddress3*        - String
139
> * *officeCity*        - String
140
> * *officeState*        - String
141
> * *officeCountry*        - String
142
> * *officePostcode*        - String
143
> * *officeEmail*        - String
144
> * *officePhone*        - String
145
> * *officeExt*        - String
146
> * *officeFax*        - String
147
> * *msisdn*        - String
148
149
* *com.cosway.bcard.bean.ResultBean*
150
> * *errorCode*    - String
151
> * *errorMessage* - String