Interface IUserSegmentationManagerSPI
-
- All Superinterfaces:
IUserSegmentationManager
- All Known Implementing Classes:
UserSegmentationManager
public interface IUserSegmentationManagerSPI extends IUserSegmentationManager
User segmentation related operations.- Since:
- 11.2.0
- Version:
- $Revision: 23034 $ $Date: 2019-08-05 16:52:47 -0300 (Mon, 05 Aug 2019) $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
deleteSegmentations(java.util.Collection<java.lang.String> ids, java.lang.String serviceInstanceId)
Delete the given segmentations.void
deleteSegmentationsByServiceInstanceId(java.lang.String serviceInstanceId)
Deletes all segmentations of the given service instance.java.util.List<IUserSegmentation>
findByServiceInstanceAndLikeName(java.lang.String name, java.lang.String serviceInstanceId)
Returns the segmentations of the given service instance that matches the givenname
parameter.IUserSegmentation
getById(java.lang.String id)
Returns the segmentation with the given identifier ornull
if no segmentation exists with the given identifier.java.util.List<IUserSegmentation>
getByServiceInstance(java.lang.String serviceInstanceId)
Returns the segmentations of the given service instance.java.util.Collection<java.lang.String>
getMemberSegmentations(java.lang.String monitorUserId)
Returns a collection of segmentations of the given user.java.util.Collection<java.lang.String>
getMemberSegmentations(java.lang.String monitorUserId, boolean useSessionCache)
Returns a collection of segmentations of the given user.java.util.Collection<java.lang.String>
getPortalMembers(java.lang.String segmentationId)
Returns the segmentation members.default java.util.Collection<java.lang.String>
getPortalMemberSegmentations(java.lang.String portalUserId)
Returns a collection of segmentations of the given (portal) user.java.util.Collection<java.lang.String>
getPortalMemberSegmentations(java.lang.String portalUserId, boolean useSessionCache)
Returns a collection of segmentations of the given (portal) user.java.util.Collection<IUserSegmentation>
getSegmentationsThatNeedToHaveMembershipUpdated()
Returns a collection of user segmentations that must have the memberships updated.IMonitorValuesProvider
getUserSegmentationMonitorValuesProvider(IUserSegmentation segmentation)
Returns aIMonitorValuesProvider
that fills user segmentation information.boolean
isMember(java.util.Collection<java.lang.String> segmentationIds, java.lang.String monitorUserId)
Verifies if a user is a member of one of the specified segmentations.
The given user identifier refers to monitor user, not to the portal user.java.lang.String
saveSegmentation(java.lang.String name, java.lang.String serviceInstanceId, org.json.JSONObject segmentationFilter)
Save the given segmentation and returns the identifier of the segmentation added or updated.IUserSegmentation
updateSegmentation(java.lang.String id, java.lang.String serviceInstanceId, org.json.JSONObject filter)
Updates the given segmentation with the given filters.-
Methods inherited from interface lumis.portal.analytics.usersegmentation.IUserSegmentationManager
getByNameAndServiceInstance, updateSegmentationMembership, updateSegmentationMembership
-
-
-
-
Method Detail
-
saveSegmentation
java.lang.String saveSegmentation(java.lang.String name, java.lang.String serviceInstanceId, org.json.JSONObject segmentationFilter) throws PortalException
Save the given segmentation and returns the identifier of the segmentation added or updated. The affected segmentation will not have an attached group.- Parameters:
name
- the segmentation name.serviceInstanceId
- the service instance identifier.segmentationFilter
- the segmentation filter.- Returns:
- the identifier of the segmentation added or updated.
- Throws:
PortalException
- Since:
- 11.2.0
-
updateSegmentation
IUserSegmentation updateSegmentation(java.lang.String id, java.lang.String serviceInstanceId, org.json.JSONObject filter) throws PortalException
Updates the given segmentation with the given filters. Does not change anything about an attached group.- Parameters:
id
- the segmentation identifier.serviceInstanceId
- the service instance identifier.filter
- the segmentation filter.- Returns:
- updated entity.
- Throws:
PortalException
- Since:
- 11.2.0
-
deleteSegmentations
void deleteSegmentations(java.util.Collection<java.lang.String> ids, java.lang.String serviceInstanceId) throws PortalException
Delete the given segmentations.- Parameters:
ids
- the segmentation identifiers.serviceInstanceId
- the service instance identifier.- Throws:
PortalException
- Since:
- 11.2.0
-
deleteSegmentationsByServiceInstanceId
void deleteSegmentationsByServiceInstanceId(java.lang.String serviceInstanceId) throws PortalException
Deletes all segmentations of the given service instance.- Parameters:
serviceInstanceId
- the service instance identifier.- Throws:
PortalException
- Since:
- 11.2.0
-
findByServiceInstanceAndLikeName
java.util.List<IUserSegmentation> findByServiceInstanceAndLikeName(java.lang.String name, java.lang.String serviceInstanceId) throws PortalException
Returns the segmentations of the given service instance that matches the givenname
parameter.- Parameters:
name
- the segmentation name.serviceInstanceId
- the service instance identifier.- Returns:
- the segmentations of the given service instance that matches the given
name
parameter. - Throws:
PortalException
- Since:
- 11.2.0
-
getById
IUserSegmentation getById(java.lang.String id) throws PortalException
Returns the segmentation with the given identifier ornull
if no segmentation exists with the given identifier.- Parameters:
id
- the segmentation identifier.- Returns:
- the segmentation with the given identifier or
null
if no segmentation exists with the given identifier. - Throws:
PortalException
- Since:
- 11.2.0
-
getByServiceInstance
java.util.List<IUserSegmentation> getByServiceInstance(java.lang.String serviceInstanceId) throws PortalException
Returns the segmentations of the given service instance.- Parameters:
serviceInstanceId
- the service instance identifier.- Returns:
- the segmentations of the given service instance.
- Throws:
PortalException
- Since:
- 11.2.0
-
isMember
boolean isMember(java.util.Collection<java.lang.String> segmentationIds, java.lang.String monitorUserId) throws PortalException
Verifies if a user is a member of one of the specified segmentations.
The given user identifier refers to monitor user, not to the portal user.- Parameters:
segmentationIds
- the segmentation identifiers.monitorUserId
- the monitor user identifier.- Returns:
- true if the user is member of any of the segmentations, false otherwise.
- Throws:
PortalException
- Since:
- 11.2.0
-
getPortalMembers
java.util.Collection<java.lang.String> getPortalMembers(java.lang.String segmentationId) throws PortalException
Returns the segmentation members. The members are monitor users.- Parameters:
segmentationId
- the segmentation identifier.- Returns:
- a collection of segmentation member identifiers.
- Throws:
PortalException
- Since:
- 12.0.0
-
getMemberSegmentations
java.util.Collection<java.lang.String> getMemberSegmentations(java.lang.String monitorUserId) throws PortalException
Returns a collection of segmentations of the given user.- Parameters:
monitorUserId
- the monitor user identifier.- Returns:
- a collection of segmentations of the given user.
- Throws:
PortalException
- Since:
- 11.2.0
-
getMemberSegmentations
java.util.Collection<java.lang.String> getMemberSegmentations(java.lang.String monitorUserId, boolean useSessionCache) throws PortalException
Returns a collection of segmentations of the given user.- Parameters:
monitorUserId
- the monitor user identifier.useSessionCache
- indicates whether session cache should be used.- Returns:
- a collection of segmentations of the given user.
- Throws:
PortalException
- Since:
- 11.2.0
-
getPortalMemberSegmentations
default java.util.Collection<java.lang.String> getPortalMemberSegmentations(java.lang.String portalUserId) throws PortalException
Returns a collection of segmentations of the given (portal) user.- Parameters:
monitorUserId
- the portal user identifier.- Returns:
- a collection of segmentations of the given (portal) user.
- Throws:
PortalException
- Since:
- 11.2.0
-
getPortalMemberSegmentations
java.util.Collection<java.lang.String> getPortalMemberSegmentations(java.lang.String portalUserId, boolean useSessionCache) throws PortalException
Returns a collection of segmentations of the given (portal) user.- Parameters:
monitorUserId
- the portal user identifier.- Returns:
- a collection of segmentations of the given (portal) user.
- Throws:
PortalException
- Since:
- 11.2.0
-
getSegmentationsThatNeedToHaveMembershipUpdated
java.util.Collection<IUserSegmentation> getSegmentationsThatNeedToHaveMembershipUpdated() throws PortalException
Returns a collection of user segmentations that must have the memberships updated.- Returns:
- a collection of user segmentations that must have the memberships updated.
- Throws:
PortalException
- Since:
- 11.2.0
-
getUserSegmentationMonitorValuesProvider
IMonitorValuesProvider getUserSegmentationMonitorValuesProvider(IUserSegmentation segmentation)
Returns aIMonitorValuesProvider
that fills user segmentation information.- Parameters:
segmentation
- the user segmentation.- Returns:
- a
IMonitorValuesProvider
that fills user segmentation information. - Since:
- 12.0.0
-
-