org.opencms.ade.galleries.shared
Class CmsGallerySearchBean

java.lang.Object
  extended by org.opencms.ade.galleries.shared.CmsGallerySearchBean
All Implemented Interfaces:
com.google.gwt.user.client.rpc.IsSerializable

public class CmsGallerySearchBean
extends java.lang.Object
implements com.google.gwt.user.client.rpc.IsSerializable

This bean represents the current search object.

The search object collects the current parameters which are used for the search and contains the search results for the current search parameters.

Since:
8.0.0

Field Summary
static int DEFAULT_MATCHES_PER_PAGE
          The default matches per page.
static int DEFAULT_TAB_ID
          The default tab id to use when the gallery is opened.
static java.lang.String DICT_NAME
          Name of the used JS variable.
 
Constructor Summary
CmsGallerySearchBean()
          Empty default constructor.
CmsGallerySearchBean(CmsGallerySearchBean searchObj)
          Constructor of the search object.
 
Method Summary
 void addCategory(java.lang.String category)
          Adds a category to the categories list.
 void addFolder(java.lang.String folder)
          Adds a new VFS folder to search in.
 void addGallery(java.lang.String gallery)
          Adds a gallery folder to the galleries list.
 void addType(java.lang.String type)
          Adds a type to the types list.
 void clearCategories()
          Clears the categories list.
 void clearFolders()
          Clears the list of VFS folders.
 void clearFullTextSearch()
          Clears the full text search.
 void clearGalleries()
          Clears the galleries list.
 void clearTypes()
          Clears the types list.
 java.util.List<java.lang.String> getCategories()
          Returns the list of the available categories.
 long getDateCreatedEnd()
          Returns the dateCreatedEnd.
 long getDateCreatedStart()
          Returns the dateCreatedStart.
 long getDateModifiedEnd()
          Returns the dateModifiedEnd.
 long getDateModifiedStart()
          Returns the dateModifiedStart.
 java.util.Set<java.lang.String> getFolders()
          Returns the list of selected VFS folders.
 java.util.List<java.lang.String> getGalleries()
          Returns the list of the available galleries.
 I_CmsGalleryProviderConstants.GalleryTabId getInitialTabId()
          Gets the initial tab id.
 int getLastPage()
          Gets the index of the last search results page.
 java.lang.String getLocale()
          Returns the search locale.
 int getMatchesPerPage()
          Returns the number of matches per search page.
 int getPage()
          Returns the page.
 java.lang.String getQuery()
          Returns the search query string.
 java.lang.String getReferencePath()
          Gets the gallery reference path.
 java.lang.String getResourcePath()
          Returns the path to the selected resource in the current search.
 java.lang.String getResourceType()
          Returns the resource type of the selected resource.
 int getResultCount()
          Returns the resultCount.
 java.util.List<CmsResultItemBean> getResults()
          Returns the results.
 CmsGallerySearchScope getScope()
          Gets the search scope.
 CmsSitemapEntryBean getSitemapPreloadData()
          Gets the sitemap preload data.
 java.lang.String getSortOrder()
          Returns the sort order of the search results.
 java.lang.String getTabId()
          Returns the tabId.
 java.util.List<java.lang.String> getTypes()
          Returns the list of the available type.
 CmsVfsEntryBean getVfsPreloadData()
          Gets the VFS preload data.
 boolean hasMore()
          Checks if there are more search items available on the next page.
 boolean isEmpty()
          Checks if any search parameter are selected.
 boolean isIgnoreSearchExclude()
          Returns the search exclude property ignore flag.
 boolean isIncludeExpired()
          Returns if the search should include expired or unreleased resources.
 void removeCategory(java.lang.String category)
          Removes a category from the categories list.
 void removeFolder(java.lang.String folder)
          Removes a folder from the folder list.
 void removeGallery(java.lang.String gallery)
          Removes a gallery folder from the galleries list.
 void removeType(java.lang.String type)
          Removes a type from the types list.
 void setCategories(java.util.List<java.lang.String> categories)
          Sets the categories.
 void setDateCreatedEnd(long dateCreatedEnd)
          Sets the dateCreatedEnd.
 void setDateCreatedStart(long dateCreatedStart)
          Sets the dateCreatedStart.
 void setDateModifiedEnd(long dateModifiedEnd)
          Sets the dateModifiedEnd.
 void setDateModifiedStart(long dateModifiedStart)
          Sets the dateModifiedStart.
 void setFolders(java.util.Set<java.lang.String> folders)
          Sets the folders to search in.
 void setGalleries(java.util.List<java.lang.String> galleries)
          Sets the galleries.
 void setIgnoreSearchExclude(boolean excludeForPageEditor)
          Sets the search exclude property ignore flag.
 void setIncludeExpired(boolean includeExpired)
          Sets if the search should include expired or unreleased resources.
 void setInitialTabId(I_CmsGalleryProviderConstants.GalleryTabId initialTabId)
          Sets the initial tab id.
 void setLastPage(int lastPage)
          Sets the index of the last search result page.
 void setLocale(java.lang.String locale)
          Sets the locale.
 void setMatchesPerPage(int matchesPerPage)
          Sets the matchesPerPage.
 void setPage(int page)
          Sets the page.
 void setQuery(java.lang.String query)
          Sets the query.
 void setReferencePath(java.lang.String referencePath)
          Sets the gallery reference path.
 void setResourcePath(java.lang.String resourcePath)
          Sets the resourcePath.
 void setResourceType(java.lang.String resourceType)
          Sets the resource type of the selected resource.
 void setResultCount(int resultCount)
          Sets the resultCount.
 void setResults(java.util.List<CmsResultItemBean> results)
          Sets the results.
 void setScope(CmsGallerySearchScope scope)
          Sets the search scope.
 void setSitemapPreloadData(CmsSitemapEntryBean preloadData)
          Sets the sitemap preload data.
 void setSortOrder(java.lang.String sortOrder)
          Sets the sortOrder.
 void setTabId(java.lang.String tabId)
          Sets the tabId.
 void setTypes(java.util.List<java.lang.String> types)
          Sets the type names.
 void setVfsPreloadData(CmsVfsEntryBean preloadData)
          Sets the VFS tree preload data.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_MATCHES_PER_PAGE

public static final int DEFAULT_MATCHES_PER_PAGE
The default matches per page.

See Also:
Constant Field Values

DEFAULT_TAB_ID

public static final int DEFAULT_TAB_ID
The default tab id to use when the gallery is opened.

See Also:
Constant Field Values

DICT_NAME

public static final java.lang.String DICT_NAME
Name of the used JS variable.

See Also:
Constant Field Values
Constructor Detail

CmsGallerySearchBean

public CmsGallerySearchBean()
Empty default constructor.


CmsGallerySearchBean

public CmsGallerySearchBean(CmsGallerySearchBean searchObj)
Constructor of the search object.

The constructor copies the content of the provided parameter to the current bean.

Parameters:
searchObj - a search object with content
Method Detail

addCategory

public void addCategory(java.lang.String category)
Adds a category to the categories list.

Parameters:
category - the category

addFolder

public void addFolder(java.lang.String folder)
Adds a new VFS folder to search in.

Parameters:
folder - the folder to add

addGallery

public void addGallery(java.lang.String gallery)
Adds a gallery folder to the galleries list.

Parameters:
gallery - the gallery

addType

public void addType(java.lang.String type)
Adds a type to the types list.

Parameters:
type - the type

clearCategories

public void clearCategories()
Clears the categories list.


clearFolders

public void clearFolders()
Clears the list of VFS folders.


clearFullTextSearch

public void clearFullTextSearch()
Clears the full text search.


clearGalleries

public void clearGalleries()
Clears the galleries list.


clearTypes

public void clearTypes()
Clears the types list.


getCategories

public java.util.List<java.lang.String> getCategories()
Returns the list of the available categories.

Returns:
the categories

getDateCreatedEnd

public long getDateCreatedEnd()
Returns the dateCreatedEnd.

Returns:
the dateCreatedEnd

getDateCreatedStart

public long getDateCreatedStart()
Returns the dateCreatedStart.

Returns:
the dateCreatedStart

getDateModifiedEnd

public long getDateModifiedEnd()
Returns the dateModifiedEnd.

Returns:
the dateModifiedEnd

getDateModifiedStart

public long getDateModifiedStart()
Returns the dateModifiedStart.

Returns:
the dateModifiedStart

getFolders

public java.util.Set<java.lang.String> getFolders()
Returns the list of selected VFS folders.

Returns:
the list of selected VFS folders

getGalleries

public java.util.List<java.lang.String> getGalleries()
Returns the list of the available galleries.

Returns:
the galleries

getInitialTabId

public I_CmsGalleryProviderConstants.GalleryTabId getInitialTabId()
Gets the initial tab id.

Returns:
the initial tab id

getLastPage

public int getLastPage()
Gets the index of the last search results page.

Returns:
the index of the last search results page

getLocale

public java.lang.String getLocale()
Returns the search locale.

Returns:
the locale

getMatchesPerPage

public int getMatchesPerPage()
Returns the number of matches per search page.

Returns:
the matchesPerPage

getPage

public int getPage()
Returns the page.

Returns:
the page

getQuery

public java.lang.String getQuery()
Returns the search query string.

Returns:
the query

getReferencePath

public java.lang.String getReferencePath()
Gets the gallery reference path.

Returns:
the gallery reference path

getResourcePath

public java.lang.String getResourcePath()
Returns the path to the selected resource in the current search.

Returns:
the path to the selected resource

getResourceType

public java.lang.String getResourceType()
Returns the resource type of the selected resource.

Returns:
the resource type

getResultCount

public int getResultCount()
Returns the resultCount.

Returns:
the resultCount

getResults

public java.util.List<CmsResultItemBean> getResults()
Returns the results.

Returns:
the results

getScope

public CmsGallerySearchScope getScope()
Gets the search scope.

Returns:
the search scope

getSitemapPreloadData

public CmsSitemapEntryBean getSitemapPreloadData()
Gets the sitemap preload data.

Returns:
the sitemap preload data

getSortOrder

public java.lang.String getSortOrder()
Returns the sort order of the search results.

Returns:
the sortOrder

getTabId

public java.lang.String getTabId()
Returns the tabId.

Returns:
the tabId

getTypes

public java.util.List<java.lang.String> getTypes()
Returns the list of the available type.

Returns:
the typeNames

getVfsPreloadData

public CmsVfsEntryBean getVfsPreloadData()
Gets the VFS preload data.

Returns:
the VFS preload data

hasMore

public boolean hasMore()
Checks if there are more search items available on the next page.

Returns:
true if there are more search results available false otherwise

isEmpty

public boolean isEmpty()
Checks if any search parameter are selected.

Returns:
false if any search parameter is selected, true if there are no search parameter selected

isIgnoreSearchExclude

public boolean isIgnoreSearchExclude()
Returns the search exclude property ignore flag.

Returns:
the search exclude property ignore flag

isIncludeExpired

public boolean isIncludeExpired()
Returns if the search should include expired or unreleased resources.

Returns:
true if the search should include expired or unreleased resources

removeCategory

public void removeCategory(java.lang.String category)
Removes a category from the categories list.

Parameters:
category - the category

removeFolder

public void removeFolder(java.lang.String folder)
Removes a folder from the folder list.

Parameters:
folder - the folder to remove

removeGallery

public void removeGallery(java.lang.String gallery)
Removes a gallery folder from the galleries list.

Parameters:
gallery - the gallery

removeType

public void removeType(java.lang.String type)
Removes a type from the types list.

Parameters:
type - the type

setCategories

public void setCategories(java.util.List<java.lang.String> categories)
Sets the categories.

Parameters:
categories - the categories to set

setDateCreatedEnd

public void setDateCreatedEnd(long dateCreatedEnd)
Sets the dateCreatedEnd.

Parameters:
dateCreatedEnd - the dateCreatedEnd to set

setDateCreatedStart

public void setDateCreatedStart(long dateCreatedStart)
Sets the dateCreatedStart.

Parameters:
dateCreatedStart - the dateCreatedStart to set

setDateModifiedEnd

public void setDateModifiedEnd(long dateModifiedEnd)
Sets the dateModifiedEnd.

Parameters:
dateModifiedEnd - the dateModifiedEnd to set

setDateModifiedStart

public void setDateModifiedStart(long dateModifiedStart)
Sets the dateModifiedStart.

Parameters:
dateModifiedStart - the dateModifiedStart to set

setFolders

public void setFolders(java.util.Set<java.lang.String> folders)
Sets the folders to search in.

Parameters:
folders - the folders

setGalleries

public void setGalleries(java.util.List<java.lang.String> galleries)
Sets the galleries.

Parameters:
galleries - the galleries to set

setIgnoreSearchExclude

public void setIgnoreSearchExclude(boolean excludeForPageEditor)
Sets the search exclude property ignore flag.

Parameters:
excludeForPageEditor - the search exclude property ignore flag

setIncludeExpired

public void setIncludeExpired(boolean includeExpired)
Sets if the search should include expired or unreleased resources.

Parameters:
includeExpired - if the search should include expired or unreleased resources

setInitialTabId

public void setInitialTabId(I_CmsGalleryProviderConstants.GalleryTabId initialTabId)
Sets the initial tab id.

Parameters:
initialTabId - the initial tab id

setLastPage

public void setLastPage(int lastPage)
Sets the index of the last search result page.

Parameters:
lastPage - the index of the last search result page

setLocale

public void setLocale(java.lang.String locale)
Sets the locale.

Parameters:
locale - the locale to set

setMatchesPerPage

public void setMatchesPerPage(int matchesPerPage)
Sets the matchesPerPage.

Parameters:
matchesPerPage - the matchesPerPage to set

setPage

public void setPage(int page)
Sets the page.

Parameters:
page - the page to set

setQuery

public void setQuery(java.lang.String query)
Sets the query.

Parameters:
query - the query to set

setReferencePath

public void setReferencePath(java.lang.String referencePath)
Sets the gallery reference path.

Parameters:
referencePath - the gallery reference path

setResourcePath

public void setResourcePath(java.lang.String resourcePath)
Sets the resourcePath.

Parameters:
resourcePath - the resourcePath to set

setResourceType

public void setResourceType(java.lang.String resourceType)
Sets the resource type of the selected resource.

Parameters:
resourceType - the resource type to set

setResultCount

public void setResultCount(int resultCount)
Sets the resultCount.

Parameters:
resultCount - the resultCount to set

setResults

public void setResults(java.util.List<CmsResultItemBean> results)
Sets the results.

Parameters:
results - the results to set

setScope

public void setScope(CmsGallerySearchScope scope)
Sets the search scope.

Parameters:
scope - the search scope

setSitemapPreloadData

public void setSitemapPreloadData(CmsSitemapEntryBean preloadData)
Sets the sitemap preload data.

Parameters:
preloadData - the sitemap preload data

setSortOrder

public void setSortOrder(java.lang.String sortOrder)
Sets the sortOrder.

Parameters:
sortOrder - the sortOrder to set

setTabId

public void setTabId(java.lang.String tabId)
Sets the tabId.

Parameters:
tabId - the tabId to set

setTypes

public void setTypes(java.util.List<java.lang.String> types)
Sets the type names.

Parameters:
types - the type names to set

setVfsPreloadData

public void setVfsPreloadData(CmsVfsEntryBean preloadData)
Sets the VFS tree preload data.

Parameters:
preloadData - the VFS tree preload data