public class DefaultProfileTransactionService extends java.lang.Object implements ProfileTransactionService
ProfileTransactionService. Communication service to send transactions to Profile| Constructor and Description |
|---|
DefaultProfileTransactionService() |
| Modifier and Type | Method and Description |
|---|---|
protected ProfileClient |
getClient() |
ProfileConfigurationService |
getProfileConfigurationService() |
Converter<ConsignmentModel,Order> |
getProfileConsignmentEventConverter() |
Converter<OrderModel,Order> |
getProfileOrderEventConverter() |
Converter<ReturnRequestModel,Order> |
getProfileReturnEventConverter() |
Converter<UserModel,User> |
getProfileUserEventConverter() |
RetrieveRestClientStrategy |
getRetrieveRestClientStrategy() |
protected static boolean |
isValidConsentReference(java.lang.String consentReferenceId) |
protected static void |
logError(java.lang.Throwable error,
java.lang.Object obj) |
protected static void |
logSuccess(java.lang.Object obj) |
protected static java.lang.String |
parseEventToJson(java.lang.Object obj) |
void |
sendConsignmentEvent(ConsignmentModel consignmentModel)
Send consignment to yprofile.
|
void |
sendLoginEvent(UserModel userModel,
java.lang.String consentReferenceId,
java.lang.String sessionId,
java.lang.String storeName)
Send user login event to yprofile.
|
protected void |
sendOrder(java.lang.String consentReference,
Order order,
java.lang.String eventType) |
void |
sendReturnOrderEvent(ReturnRequestModel returnRequestModel)
Send return to yprofile.
|
void |
sendSubmitOrderEvent(OrderModel orderModel)
Send order to yprofile.
|
protected void |
sendUserEvent(UserModel userModel,
java.lang.String consentReferenceId,
java.lang.String sessionId,
java.lang.String storeName,
java.lang.String eventType) |
void |
sendUserRegistrationEvent(UserModel userModel,
java.lang.String consentReferenceId,
java.lang.String sessionId,
java.lang.String storeName)
Send user registration event to yprofile.
|
void |
setProfileConfigurationService(ProfileConfigurationService profileConfigurationService) |
void |
setProfileConsignmentEventConverter(Converter<ConsignmentModel,Order> profileConsignmentEventConverter) |
void |
setProfileOrderEventConverter(Converter<OrderModel,Order> profileOrderEventConverter) |
void |
setProfileReturnEventConverter(Converter<ReturnRequestModel,Order> profileReturnEventConverter) |
void |
setProfileUserEventConverter(Converter<UserModel,User> profileUserEventConverter) |
void |
setRetrieveRestClientStrategy(RetrieveRestClientStrategy retrieveRestClientStrategy) |
protected boolean |
shouldSendEvent(java.lang.String consentReference,
Order order) |
public void sendSubmitOrderEvent(OrderModel orderModel)
sendSubmitOrderEvent in interface ProfileTransactionServiceorderModel - the order modelpublic void sendConsignmentEvent(ConsignmentModel consignmentModel)
sendConsignmentEvent in interface ProfileTransactionServiceconsignmentModel - the consignment modelpublic void sendReturnOrderEvent(ReturnRequestModel returnRequestModel)
sendReturnOrderEvent in interface ProfileTransactionServicereturnRequestModel - the return requestprotected void sendOrder(java.lang.String consentReference,
Order order,
java.lang.String eventType)
protected boolean shouldSendEvent(java.lang.String consentReference,
Order order)
public void sendUserRegistrationEvent(UserModel userModel, java.lang.String consentReferenceId, java.lang.String sessionId, java.lang.String storeName)
sendUserRegistrationEvent in interface ProfileTransactionServiceuserModel - the user modelconsentReferenceId - consent refrencesessionId - ec session idstoreName - storefront name like 'electronics'public void sendLoginEvent(UserModel userModel, java.lang.String consentReferenceId, java.lang.String sessionId, java.lang.String storeName)
sendLoginEvent in interface ProfileTransactionServiceuserModel - the user modelconsentReferenceId - consent refrencesessionId - ec session idstoreName - storefront name like 'electronics'protected void sendUserEvent(UserModel userModel, java.lang.String consentReferenceId, java.lang.String sessionId, java.lang.String storeName, java.lang.String eventType)
protected static boolean isValidConsentReference(java.lang.String consentReferenceId)
protected static void logSuccess(java.lang.Object obj)
protected static void logError(java.lang.Throwable error,
java.lang.Object obj)
protected static java.lang.String parseEventToJson(java.lang.Object obj)
protected ProfileClient getClient()
public RetrieveRestClientStrategy getRetrieveRestClientStrategy()
public void setRetrieveRestClientStrategy(RetrieveRestClientStrategy retrieveRestClientStrategy)
public ProfileConfigurationService getProfileConfigurationService()
public void setProfileConfigurationService(ProfileConfigurationService profileConfigurationService)
public Converter<OrderModel,Order> getProfileOrderEventConverter()
public void setProfileOrderEventConverter(Converter<OrderModel,Order> profileOrderEventConverter)
public Converter<ConsignmentModel,Order> getProfileConsignmentEventConverter()
public void setProfileConsignmentEventConverter(Converter<ConsignmentModel,Order> profileConsignmentEventConverter)
public Converter<ReturnRequestModel,Order> getProfileReturnEventConverter()
public void setProfileReturnEventConverter(Converter<ReturnRequestModel,Order> profileReturnEventConverter)
Copyright © 2018 SAP SE. All Rights Reserved.