Class TargetGroupSegmentsProvider
- java.lang.Object
-
- com.hybris.ymkt.personalization.segment.TargetGroupSegmentsProvider
-
- All Implemented Interfaces:
CxProvider,UserSegmentsProvider
public class TargetGroupSegmentsProvider extends java.lang.Object implements UserSegmentsProvider
This class will create segments in the personalization of SmartEdit by retrieving target group values from yMKT. This feature will only work for Logged In users that have the personalization consent approved. COOKIE_ID users is excluded here, because the API does not support "Shareable" origin IDs
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringsegmentPrefixprotected booleantargetGroupEnabledprotected TargetGroupServicetargetGroupServiceprotected UserContextServiceuserContextServiceprotected UserServiceuserService-
Fields inherited from interface de.hybris.platform.personalizationintegration.segment.CxProvider
DEFAULT_PROVIDER_ID
-
-
Constructor Summary
Constructors Constructor Description TargetGroupSegmentsProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected SegmentMappingDataconvert(java.lang.String targetGroupId)java.util.List<SegmentMappingData>getUserSegments(UserModel user)Method returning segments assigned to uservoidsetSegmentPrefix(java.lang.String segmentPrefix)voidsetTargetGroupEnabled(boolean targetGroupEnabled)voidsetTargetGroupService(TargetGroupService targetGroupService)voidsetUserContextService(UserContextService userContextService)voidsetUserService(UserService userService)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.hybris.platform.personalizationintegration.segment.CxProvider
getProviderId
-
-
-
-
Field Detail
-
segmentPrefix
protected java.lang.String segmentPrefix
-
targetGroupEnabled
protected boolean targetGroupEnabled
-
targetGroupService
protected TargetGroupService targetGroupService
-
userContextService
protected UserContextService userContextService
-
userService
protected UserService userService
-
-
Method Detail
-
convert
protected SegmentMappingData convert(java.lang.String targetGroupId)
-
getUserSegments
public java.util.List<SegmentMappingData> getUserSegments(UserModel user)
Description copied from interface:UserSegmentsProviderMethod returning segments assigned to user- Specified by:
getUserSegmentsin interfaceUserSegmentsProvider- Parameters:
user- User model- Returns:
- segments assigned to user or null if segments should not be updated
-
setSegmentPrefix
public void setSegmentPrefix(java.lang.String segmentPrefix)
-
setTargetGroupEnabled
public void setTargetGroupEnabled(boolean targetGroupEnabled)
-
setTargetGroupService
public void setTargetGroupService(TargetGroupService targetGroupService)
-
setUserContextService
public void setUserContextService(UserContextService userContextService)
-
setUserService
public void setUserService(UserService userService)
-
-