Package com.portal.app.cc.sharing
Class PDiscountSharingController
java.lang.Object
com.portal.app.cc.sharing.PSharingController
com.portal.app.cc.sharing.PDiscountSharingController
This is extends
PSharingController
class, which carries all
the business logic related to data for discount sharing.
The opcode calls are done in this class. The controller separation
logic is implemented in this controller so that this
controller can be customized.-
Field Summary
Fields inherited from class com.portal.app.cc.sharing.PSharingController
db, id, mGroupType, mSharingType, sharingArrayField, sharingPoidField
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor to initializemGroupType
,mSharingType
,sharingArrayField
andsharingPoidField
. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
extractGroupSharingsFromFList
(PGroupData gData, Enumeration sharingValueEnum, HashMap indexMapping, Poid accPoid) This method will extract the discounts from the output flist and stored the discounts intoPGroupData
object.getAllMemberServices
(Poid[] acctPoids, Poid parentServicePoid) getAvailableSharingObjects
(Poid servicePoid) This method returns available discount(s) of the given service poid.protected void
prepareFListforAGroupMember
(FList memFList, PSharingItemData sid) This method prepares the input flist for discounts which are becoming members of group.protected void
prepareFListforGroupInfoSharings
(FList sharingFList) This will prepare an input flist for discounts while getting the group information.protected void
prepareIndexMapping
(HashMap indexMapping, SparseArray sharingsArray) This method will prepare the indexes hashmap for each and every discount purchased by the account.Methods inherited from class com.portal.app.cc.sharing.PSharingController
acceptParticipation, addMembersToCollectionGroup, addMembersToGroup, createGroup, deleteCollectionMembers, deleteGroups, deleteMembers, deleteMembersFromGroup, fillBillinfoData, fillPayinfoData, getAllMemberServices, getAllServices, getCollectionsGroupMembers, getCurrentAccountNo, getGlobalCSGMemberServices, getGroupInfo, getGroupMembers, getGroupMembersInfoArray, getGroupType, getMemberData, getOwnershipData, getParticipatingGroups, getServiceLoginAndType, isAccountHavingDiscounts, isAccountPoidTypeOnly, isGlobalCSG, isServicePoidTypeOnly, modifyGroup, search, search, searchWithInOperator, setPriorities
-
Constructor Details
-
PDiscountSharingController
public PDiscountSharingController()Default constructor to initializemGroupType
,mSharingType
,sharingArrayField
andsharingPoidField
.
-
-
Method Details
-
prepareIndexMapping
protected void prepareIndexMapping(HashMap indexMapping, SparseArray sharingsArray) throws EBufException This method will prepare the indexes hashmap for each and every discount purchased by the account. This will maintain key as discount poid and node location to differentiate when an account purchase same discount more than once.- Specified by:
prepareIndexMapping
in classPSharingController
- Parameters:
indexMapping
- HashMapsharingsArray
- SparseArray: The part of group output flist having the discounts as group members.- Throws:
EBufException
-
prepareFListforGroupInfoSharings
This will prepare an input flist for discounts while getting the group information.- Specified by:
prepareFListforGroupInfoSharings
in classPSharingController
- Parameters:
sharingFList
- FList the input flist.
-
extractGroupSharingsFromFList
protected void extractGroupSharingsFromFList(PGroupData gData, Enumeration sharingValueEnum, HashMap indexMapping, Poid accPoid) throws EBufException This method will extract the discounts from the output flist and stored the discounts intoPGroupData
object.- Specified by:
extractGroupSharingsFromFList
in classPSharingController
- Parameters:
gData
- PGroupData the group data which contains all the info related to sharing groupsharingValueEnum
- Enumeration the partial output flistindexMapping
- HashMap the indexed map to get the each and every discounts index in sharing group with respect to the node locationaccPoid
- Poid the account poid.- Throws:
EBufException
-
prepareFListforAGroupMember
This method prepares the input flist for discounts which are becoming members of group.- Specified by:
prepareFListforAGroupMember
in classPSharingController
- Parameters:
memFList
- FList the input flist.sid
- PSharingItemData the discount objects information which becomming the member of a group.
-
getAvailableSharingObjects
This method returns available discount(s) of the given service poid.- Specified by:
getAvailableSharingObjects
in classPSharingController
- Throws:
SharingException
-
getAllMemberServices
public ArrayList getAllMemberServices(Poid[] acctPoids, Poid parentServicePoid) throws SharingException - Throws:
SharingException
-