public class CompareUtil
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
CompareUtil.RecordType |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
RECORD_TYPE |
Constructor and Description |
---|
CompareUtil() |
Modifier and Type | Method and Description |
---|---|
static CompareGridModel |
getCompareConfig(javax.portlet.PortletRequest request,
javax.portlet.PortletResponse response,
CompareEventParam cep,
java.util.Map<java.lang.String,FormatSettings> formatters,
SemanticView semanticView,
java.util.List<java.lang.String> columns)
Called when the compare action is invoked.
|
static java.util.List<CompareGridRecordModel> |
getFilteredData(java.util.List<java.util.Map<java.lang.String,java.util.List<java.lang.String>>> records,
SemanticView mergedSemanticView,
javax.portlet.PortletRequest request,
CompareUtil.RecordType recordType,
java.util.Map<java.lang.String,FormatSettings> formatters,
java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> referenceMap)
Filter the data according to the attribute settings in preferences and control panel
|
protected static java.lang.String[] |
getRecordIds(javax.portlet.PortletRequest request,
java.lang.String ids,
CompareUtil.RecordType type)
Returns the IDs of the records required.
|
static java.util.List<java.util.Map<java.lang.String,java.util.List<java.lang.String>>> |
getRecords(javax.portlet.PortletRequest request,
java.lang.String[] recordIDs,
CompareUtil.RecordType recordType,
DataSource ds,
SemanticView semanticView,
java.util.List<java.lang.String> columns,
java.util.Map<java.lang.String,FormatSettings> formatters)
Returns the a list of records that contain all the attribute values of it
|
protected static CompareUtil.RecordType |
getRecordType(javax.portlet.PortletRequest request,
javax.portlet.PortletResponse response)
Returns the record type.
|
protected static java.lang.String[] |
removeEmptyIds(java.lang.String[] recordIds)
Removes the empty ids in the id list
|
public static final java.lang.String RECORD_TYPE
public static CompareGridModel getCompareConfig(javax.portlet.PortletRequest request, javax.portlet.PortletResponse response, CompareEventParam cep, java.util.Map<java.lang.String,FormatSettings> formatters, SemanticView semanticView, java.util.List<java.lang.String> columns) throws CompareException, javax.portlet.PortletException
CompareException
javax.portlet.PortletException
protected static java.lang.String[] getRecordIds(javax.portlet.PortletRequest request, java.lang.String ids, CompareUtil.RecordType type) throws CompareException, javax.portlet.PortletException
request
- javax.portlet.PortletException
CompareException
protected static java.lang.String[] removeEmptyIds(java.lang.String[] recordIds)
recordIds
- request
- public static java.util.List<java.util.Map<java.lang.String,java.util.List<java.lang.String>>> getRecords(javax.portlet.PortletRequest request, java.lang.String[] recordIDs, CompareUtil.RecordType recordType, DataSource ds, SemanticView semanticView, java.util.List<java.lang.String> columns, java.util.Map<java.lang.String,FormatSettings> formatters) throws CompareException, javax.portlet.PortletException
request
- recordIDs
- javax.portlet.PortletException
- - if the exception we catch is something we cannot handleCompareException
- - if the exception we catch is something we can handleprotected static CompareUtil.RecordType getRecordType(javax.portlet.PortletRequest request, javax.portlet.PortletResponse response) throws javax.portlet.PortletException
request
- javax.portlet.PortletException
public static java.util.List<CompareGridRecordModel> getFilteredData(java.util.List<java.util.Map<java.lang.String,java.util.List<java.lang.String>>> records, SemanticView mergedSemanticView, javax.portlet.PortletRequest request, CompareUtil.RecordType recordType, java.util.Map<java.lang.String,FormatSettings> formatters, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> referenceMap)
records
- The records get from MDEXexistedSemanticView
- request
- recordType
- The type of record passed inisNewEvent
- Copyright 2003, 2014, Oracle and/or its affiliates. All rights reserved.