Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.platform.contentview.jsf
Interface ContentViewService

All Superinterfaces:
Serializable
All Known Implementing Classes:
ContentViewServiceImpl

public interface ContentViewService
extends Serializable

Service handling content views and associated page providers.

Since:
5.4
Author:
Anahide Tchertchian

Method Summary
 ContentView getContentView(String name)
          Returns the content view with given name, or null if not found.
 ContentViewHeader getContentViewHeader(String name)
          Returns the content view header, or null if not found.
 Set<ContentViewHeader> getContentViewHeaders()
          Returns all the registered content view headers, or an empty set if no content view is registered.
 Set<ContentViewHeader> getContentViewHeaders(String flag)
          Returns all the registered content view headers with given flag declared on their definition
 Set<String> getContentViewNames()
          Returns all the registered content view names, or an empty set if no content view is registered.
 Set<String> getContentViewNames(String flag)
          Returns all the registered content view names with given flag declared on their definition
 PageProvider<?> getPageProvider(String contentViewName, List<SortInfo> sortInfos, Long pageSize, Long currentPage, Object... parameters)
          Returns the page provider computed from the content view with given name.
 ContentView restoreContentView(ContentViewState contentViewState)
          Restores a content view given a state.
 ContentViewState saveContentView(ContentView contentView)
          Returns the state of this content view.
 

Method Detail

getContentView

ContentView getContentView(String name)
                           throws ClientException
Returns the content view with given name, or null if not found.

Throws:
ClientException

getContentViewHeader

ContentViewHeader getContentViewHeader(String name)
Returns the content view header, or null if not found.


getContentViewNames

Set<String> getContentViewNames()
Returns all the registered content view names, or an empty set if no content view is registered.


getContentViewHeaders

Set<ContentViewHeader> getContentViewHeaders()
Returns all the registered content view headers, or an empty set if no content view is registered.


getContentViewNames

Set<String> getContentViewNames(String flag)
Returns all the registered content view names with given flag declared on their definition


getContentViewHeaders

Set<ContentViewHeader> getContentViewHeaders(String flag)
Returns all the registered content view headers with given flag declared on their definition

Since:
5.4.2

getPageProvider

PageProvider<?> getPageProvider(String contentViewName,
                                List<SortInfo> sortInfos,
                                Long pageSize,
                                Long currentPage,
                                Object... parameters)
                                throws ClientException
Returns the page provider computed from the content view with given name. Its properties are resolved using current FacesContext instance if they are EL Expressions.

If not null, parameters sortInfos and pageSize will override information computed in the XML file. If not null, currentPage will override default current page (0).

Throws:
ClientException

saveContentView

ContentViewState saveContentView(ContentView contentView)
Returns the state of this content view.

This state can be used to restore the content view in another context.

Parameters:
contentView -
Since:
5.4.2
See Also:
#restoreContentView(ContentViewState, CoreSession)

restoreContentView

ContentView restoreContentView(ContentViewState contentViewState)
                               throws ClientException
Restores a content view given a state.

The core session is only useful when restoring a content view defining a page provider mapped to a document. It is used to initialize this document.

Throws:
ClientException
Since:
5.4.2
See Also:
saveContentView(ContentView)

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.