Interface PageSource
- All Known Implementing Classes:
PageSourceImpl
public interface PageSource
Access to localized page instances (which are now shared singletons, starting in release 5.2).
This service is a wrapper around the
PageLoader
that caches the loaded pages.- Since:
- 5.2.0
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Clears the source's cache of loaded pages.Returns all currently loaded pages.Returns a loaded instance of the indicated page, using the Locale and other information from theComponentResourceSelector
obtained from theComponentRequestSelectorAnalyzer
.
-
Method Details
-
clearCache
void clearCache()Clears the source's cache of loaded pages. This occurs when an outside change to the world invalidates created page instances. Introduced to handle the case where a page has aDynamicTemplate
, but the underlyingResource
is noticed to have changed.- Since:
- 5.3
-
getPage
Returns a loaded instance of the indicated page, using the Locale and other information from theComponentResourceSelector
obtained from theComponentRequestSelectorAnalyzer
.- Parameters:
canonicalPageName
-- Returns:
- existing, or newly created, page instance
-
getAllPages
Set<Page> getAllPages()Returns all currently loaded pages. This will include any previously loaded pages not yet reclaimed by the garbage collector, and may include the same page loaded for differentComponentResourceSelector
s. This is needed for reporting purposes only.- Since:
- 5.3
- See Also:
-