Class FieldReportCSV
- java.lang.Object
-
- lumis.service.analytics.usersegmentation.rest.FieldReportCSV
-
- All Implemented Interfaces:
Comparable<FieldReportCSV>
public class FieldReportCSV extends Object implements Comparable<FieldReportCSV>
A class to represents a abstract elasticsearch field that will pass in request parameters for download CSV User Segmentation. We have two format cases: "_userAttribue_:" and " ". Examples: "_userAttribue_:TEXT" and "lum_monitoruser.name.full.token". This class also knows how to get a data from a elasticsearch document - this class is like a reflection elasticsearch field.
- Since:
- 11.1.0
- Version:
- $Revision: 24476 $ $Date: 2021-04-28 11:28:23 -0300 (Wed, 28 Apr 2021) $
-
-
Constructor Summary
Constructors Constructor Description FieldReportCSV(String requestFieldCode)
Constructor that receive a param field.FieldReportCSV(DocumentTypeField documentType)
Create a field by {link DocumentTypeField}FieldReportCSV(UserAttribute userAttribute)
Create a field by {link UserAttribute}
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(FieldReportCSV o)
String
getDocumentValue(MonitorUserDocument doc)
Return the value in elasticsearch document that FieldReportCSV represents.String
getLabel(ServiceConfig serviceConfig)
Whill return self label field localized by service resource stringString
getRequestFieldCode()
Return a code request for this field.void
validateAccess(String serviceInstanceId)
Throws exception if the field is not allowed for given service instance.
-
-
-
Constructor Detail
-
FieldReportCSV
public FieldReportCSV(String requestFieldCode)
Constructor that receive a param field.- Parameters:
requestFieldCode
- can be "_userAttribue_:" or " ". Examples: "_userAttribue_:TEXT" and "lum_monitoruser.name.full.token". - Since:
- 11.1.0
-
FieldReportCSV
public FieldReportCSV(DocumentTypeField documentType)
Create a field by {link DocumentTypeField}- Parameters:
documentType
- the source metainfo for field.- Since:
- 11.1.0
-
FieldReportCSV
public FieldReportCSV(UserAttribute userAttribute)
Create a field by {link UserAttribute}- Parameters:
userAttribute
- the source metainfo for field.- Since:
- 11.1.0
-
-
Method Detail
-
getLabel
public String getLabel(ServiceConfig serviceConfig) throws PortalException
Whill return self label field localized by service resource string- Parameters:
serviceConfig
- source of resource string.- Returns:
- localized self label.
- Throws:
PortalException
- Since:
- 11.1.0
-
getDocumentValue
public String getDocumentValue(MonitorUserDocument doc)
Return the value in elasticsearch document that FieldReportCSV represents.- Parameters:
doc
-- Returns:
- Since:
- 11.1.0
-
getRequestFieldCode
public String getRequestFieldCode()
Return a code request for this field.- Returns:
- the code request.
- Since:
- 11.1.0
-
compareTo
public int compareTo(FieldReportCSV o)
- Specified by:
compareTo
in interfaceComparable<FieldReportCSV>
-
validateAccess
public void validateAccess(String serviceInstanceId)
Throws exception if the field is not allowed for given service instance.- Parameters:
serviceInstanceId
- the service instance identifier.- Since:
- 14.0.0
-
-