public class NoteQueryParameters extends TimelineQueryParameters
QueryParameters.OrderDirection
Modifier and Type | Field and Description |
---|---|
static String |
PARAM_NOTE_STATUS
Parameter name in Query for the NoteStatus
|
PARAM_ATTACHMENT_REPO_CONNECTOR_ID, PARAM_BLOG_ID, PARAM_DISCUSSION_ID, PARAM_FILTER, PARAM_LOWER_TAG_DATE, PARAM_MAX_RANK, PARAM_MIN_RANK, PARAM_NOTE_ID, PARAM_RESOURCE_ID, PARAM_TAG_PREFIX, PARAM_UPPER_TAG_DATE, PARAM_USER_ID, PARAM_USER_TO_BE_NOTIFIED
PARAM_LAST_MODIFICATION_DATE, PARAM_USER_ROLE_FILTER, PLACEHOLDER_USER_ALIAS
SORT_ASCENDING, SORT_DESCENDING
Constructor and Description |
---|
NoteQueryParameters()
Construct me with the right query definition
|
Modifier and Type | Method and Description |
---|---|
static NoteQueryParameters |
clone(NoteQueryParameters parameters)
Create a new NoteQueryParameters by cloning others.
|
static NoteQueryParameters |
clone(TimelineQueryParameters queryParameters)
Create a new NoteQueryInstance that takes the common
TimelineQueryParameters
Parameters. |
DiscussionFilterMode |
getDiscussionFilterModeForFiltering()
The discussion filter mode that should be used for filtering.
|
String |
getOriginalPostId() |
Map<String,Object> |
getParameters()
Get the parameters of this instances, the names are the keys
|
ResultSpecification |
getResultSpecification()
Get the result specification to be used
|
Date |
getRetrieveOnlyNotesAfterDate() |
Long |
getRetrieveOnlyNotesAfterId() |
Date |
getRetrieveOnlyNotesBeforeDate() |
Long |
getRetrieveOnlyNotesBeforeId() |
QueryParameters.OrderDirection |
getSortByDate() |
QueryParameters.OrderDirection |
getSortById() |
NoteStatus |
getStatus() |
boolean |
isDiscussionDependentRootNotesFilter()
See also
isDiscussionIndependentFilter() |
boolean |
isDiscussionIndependentFilter()
Return whether the current filters are discussion independent which means that, no matter
what value a filter has the result set will always contain all the notes of a discussion the
current user is allowed to read.
|
boolean |
isFavoriteFeedAndUnfiltered() |
boolean |
isFeedFiltered()
Checks if the user has filtered the message feed by standard filters.
|
boolean |
isFeedFiltered(boolean allowBlogFilter,
boolean allowDateFilter,
boolean allowDiscussionIdFilter)
Checks if the user has filtered the message feed allowing to ignore specific parameters
|
boolean |
isFollowingFeedAndUnfiltered() |
boolean |
isNotificationFeed() |
boolean |
isThreadedView() |
void |
setOriginalPostId(String originalPostId) |
void |
setRetrieveOnlyNotesAfterDate(Date retrieveOnlyNotesAfterDate) |
void |
setRetrieveOnlyNotesAfterId(Long noteId)
Note: If also the lowerTagDate filter is set and the lowerTagDate > creationDate of
retrieveOnlyNotesBeforeId a standard filtering for lowerTagDate will be done.
|
void |
setRetrieveOnlyNotesBeforeDate(Date retrieveOnlyNotesBeforeDate)
Filter to restrict the result to notes that were created before this date.
|
void |
setRetrieveOnlyNotesBeforeId(Long noteId)
Filter to restrict the result to notes that have an ID that is lower than this one.
|
void |
setSortByDate(QueryParameters.OrderDirection orderDirection)
Method to set the date sorting.
|
void |
setSortById(QueryParameters.OrderDirection sortById)
Method to set the id sorting.
|
void |
setStatus(NoteStatus status) |
void |
setTimelineFilterViewType(TimelineFilterViewType timelineFilterViewType) |
addTagId, addTagStoreTagId, addTagStoreTagId, createParameterName, getAttachmentContentIds, getAttachmentRepositoryConnectorId, getAttachmentRepositoryConnectorIds, getDiscussionFilterMode, getDiscussionId, getExcludeNoteStatus, getFullTextSearchFilters, getFullTextSearchParameterNames, getLogicalTags, getLowerTagDate, getMaximumRank, getMinimumRank, getNoteId, getNumberOfTagsToFilter, getResourceId, getTagIds, getTagPrefix, getTagStoreAliases, getTagStoreTagIds, getTopicSearchParameterNames, getTypeSpecificExtension, getUpperTagDate, getUserAliases, getUserIds, getUserIdsToIgnore, getUserToBeNotified, isAllowDuplicateResults, isDirectMessage, isFavorites, isIncludeStartDate, isMentionDiscussionAuthors, isMentionTopicAuthors, isMentionTopicManagers, isMentionTopicReaders, isMultilingualTagPrefixSearch, isQueryForAdditionalDMs, isRankFilterActive, isRetrieveOnlyFollowedItems, isSearchOnlyExtensionSpecificFields, isSortByDayDateAndRank, isTimeLimitsQueryRequired, needTransformListItem, setAllowDuplicateResults, setAttachmentContentIds, setAttachmentRepositoryConnectorId, setAttachmentRepositoryConnectorIds, setDirectMessage, setDiscussionFilterMode, setDiscussionId, setExcludeNoteStatus, setFavorites, setFullTextSearchFilters, setIncludeStartDate, setLogicalTags, setLowerTagDate, setMaximumRank, setMentionDiscussionAuthors, setMentionTopicAuthors, setMentionTopicManagers, setMentionTopicReaders, setMinimumRank, setNoteId, setQueryForAdditionalDMs, setResourceId, setRetrieveOnlyFollowedItems, setSortByDayDateAndRank, setTagIds, setTagPrefix, setTagStoreAliases, setTimeLimitsQueryRequired, setTopicSearchFilters, setTypeSpecificExtension, setUpperTagDate, setUserAliases, setUserIds, setUserIdsToIgnore, setUserToBeNotified
addRoleToExclude, addRoleToInclude, addUserTagIds, addUserTagStoreTagId, addUserTagStoreTagId, getExcludeStatusFilter, getIncludeStatusFilter, getLastModifiedAfter, getMatchMode, getRolesToExclude, getRolesToInclude, getUserSearchFilters, getUserSearchParameterNames, getUserTagIds, getUserTagStoreTagIds, isHideSelectedTags, isIgnoreEmailField, isRetrieveOnlyFollowedUsers, setExcludeStatusFilter, setHideSelectedTags, setIncludeStatusFilter, setLastModifiedAfter, setMatchMode, setRetrieveOnlyFollowedUsers, setUserSearchFilters, setUserSearchFilters, sortByEmailAsc, sortByFirstNameAsc, sortByLastNameAsc, transformResultItem
addPropertyFilter, getPropertyFilters
addParameter, addParameter, addSortField, addSortField, createParameterNamesForSearch, getDatabaseConfiguration, getLanguageCode, getPageInformation, getPageInformation, getSortString, isLimitResultSet, isLimitResultSetAvodingDuplicates, putParameter, putParametersForSearch, putParametersForSearch, setLanguageCode, setLimitResultSet, setLimitResultSetAvodingDuplicates, setResultSpecification, validateLong
public static final String PARAM_NOTE_STATUS
public NoteQueryParameters()
public static NoteQueryParameters clone(NoteQueryParameters parameters)
parameters
- The parameters to clone.NoteQueryParameters
with the filters set as in queryInstancepublic static NoteQueryParameters clone(TimelineQueryParameters queryParameters)
TimelineQueryParameters
Parameters.queryParameters
- The query instance containing all parameters.NoteQueryParameters
with the filters set as in queryInstancepublic DiscussionFilterMode getDiscussionFilterModeForFiltering()
getDiscussionFilterModeForFiltering
in class TimelineQueryParameters
public String getOriginalPostId()
public Map<String,Object> getParameters()
getParameters
in class TimelineQueryParameters
public ResultSpecification getResultSpecification()
getResultSpecification
in class QueryParameters
ResultSpecification
public Date getRetrieveOnlyNotesAfterDate()
public Long getRetrieveOnlyNotesAfterId()
null
for no boundary.public Date getRetrieveOnlyNotesBeforeDate()
getRetrieveOnlyNotesBeforeId()
will be ignored.public Long getRetrieveOnlyNotesBeforeId()
null
for no boundary. If null the value returned by
getRetrieveOnlyNotesBeforeDate()
will be ignored. In case the discussion
filter mode is set to DiscussionFilterMode.IS_ROOT
this ID should be a
discussion ID.public QueryParameters.OrderDirection getSortByDate()
public QueryParameters.OrderDirection getSortById()
public NoteStatus getStatus()
public boolean isDiscussionDependentRootNotesFilter()
isDiscussionIndependentFilter()
public boolean isDiscussionIndependentFilter()
public boolean isFavoriteFeedAndUnfiltered()
public boolean isFeedFiltered()
public boolean isFeedFiltered(boolean allowBlogFilter, boolean allowDateFilter, boolean allowDiscussionIdFilter)
allowBlogFilter
- true to ignore the topic filter when checking for set filtersallowDateFilter
- true to ignore the date filter when checking for set filtersallowDiscussionIdFilter
- true to ignore the discussionId filter when checking for set filterspublic boolean isFollowingFeedAndUnfiltered()
public boolean isNotificationFeed()
public boolean isThreadedView()
public void setOriginalPostId(String originalPostId)
originalPostId
- the originalPostId to setpublic void setRetrieveOnlyNotesAfterDate(Date retrieveOnlyNotesAfterDate)
retrieveOnlyNotesAfterDate
- Date, which is used to get another note, if the original note for
RetrieveOnlyNotesAfterId was deleted. This should be the same date as the creation
date of the original note.public void setRetrieveOnlyNotesAfterId(Long noteId)
noteId
- All returning notes will have a higher id than this one.public void setRetrieveOnlyNotesBeforeDate(Date retrieveOnlyNotesBeforeDate)
DiscussionFilterMode.IS_ROOT
this date is checked
against the lastNoteCreationDate of the discussion. Note: If also the upperTagDate
filter is set and the upperTagDate < retrieveOnlyNotesBeforeDate a standard filtering for
upperTagDate will be done.retrieveOnlyNotesBeforeDate
- Date for restricting the result to notes that were create before this datepublic void setRetrieveOnlyNotesBeforeId(Long noteId)
DiscussionFilterMode.IS_ROOT
this ID should be a
discussion ID.noteId
- note ID to use for restricting the result to notes with an ID smaller than thispublic void setSortByDate(QueryParameters.OrderDirection orderDirection)
orderDirection
- Sets the type of date sorting. Set null
to disable ordering for the
date.public void setSortById(QueryParameters.OrderDirection sortById)
sortById
- Sets the type of id sorting. Set null
to disable ordering for the id.public void setStatus(NoteStatus status)
status
- the status to setpublic void setTimelineFilterViewType(TimelineFilterViewType timelineFilterViewType)
timelineFilterViewType
- the view type to use. The view type defines mainly the result but also has impact
on the filter. If setting it to COMMENT it will also set the DiscussionFilterMode
to IS_ROOTCopyright © 2019 Communote team. All rights reserved.