public class VirtualYearPage extends AbstractBlogPage
Page.LinkType, Page.PageType| Modifier and Type | Field and Description |
|---|---|
private BlogCacheManager |
_cacheManager |
private String |
_i18nCatalogue |
private I18nUtils |
_i18nUtils |
private AmetysObjectResolver |
_resolver |
private PagesContainer |
_root |
private SiteConfigurationExtensionPoint |
_siteConf |
private SkinsManager |
_skinsManager |
private String |
_title |
private int |
_year |
BLOG_MONTH_TEMPLATE, BLOG_POST_TEMPLATE, BLOG_TAG_TEMPLATE, BLOG_YEAR_TEMPLATE| Constructor and Description |
|---|
VirtualYearPage(AmetysObjectResolver resolver,
BlogCacheManager cacheManager,
SkinsManager skinsManager,
I18nUtils i18nCache,
String i18nCatalogue,
SiteConfigurationExtensionPoint siteConf,
int year,
String title,
PagesContainer root)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
<A extends AmetysObject> |
getChild(String path)
Retrieves a given child from its relative path.
|
Page |
getChildPageAt(int index)
Gets the child
Page at the given position |
AmetysObjectIterable<? extends AmetysObject> |
getChildren()
Retrieves children of the current object.
|
AmetysObjectIterable<? extends Page> |
getChildrenPages()
Retrieves child pages.
|
AmetysObjectIterable<? extends Page> |
getChildrenPages(boolean includeInvisiblePages)
Retrieves child pages.
|
protected Zone |
getDefaultZone()
Get the "default" zone.
|
int |
getDepth()
Get the page depth
|
String |
getId()
Retrieves the unique identifier of this AmetysObject.
It must be unique in the whole repository and must never be null. It must conform to the URI syntax: <protocol>://<protocol-specific-part> |
String |
getLongTitle()
Retrieves the long title.
|
CompositeMetadata |
getMetadataHolder()
Returns the root
CompositeMetadata of this AmetysObject. |
String |
getName()
Retrieves the name of the current object.
|
PagesContainer |
getParent()
Returns the parent object in the Ametys hierarchy.
|
String |
getParentPath()
Returns the path of the parent object in the Ametys hierarchy.
|
String |
getPath()
Retrieves the path of the current object.
|
String |
getPathInSitemap()
Computes the path relative to the current sitemap.
|
Set<String> |
getReferers()
Retrieves all
AmetysObject ids referencing this page. |
ResourceCollection |
getRootAttachments()
Retrieves the attachments root node
|
Site |
getSite()
Returns this object's site.
|
Sitemap |
getSitemap()
Retrieves the sitemap containing the current sitemap.
|
String |
getSitemapName()
Returns this page's sitemap name
|
String |
getSiteName()
Returns this object's site name.
|
Set<String> |
getTags()
Retrieves current tags.
|
String |
getTemplate()
Retrieves the template name.
|
String |
getTitle()
Retrieves the title.
|
String |
getURL()
Retrieves the linked URL.
|
Page.LinkType |
getURLType()
Retrieves the linked URL type.
|
int |
getYear()
Get the page's year.
|
boolean |
hasChild(String name)
Tests if this Object has at least one child with the given name.
|
boolean |
isVisible()
Determine if the page is visible into navigation elements
|
getReferencePage, getType, getZone, getZones, hasZoneclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetChildAt, getChildPositionequals, hashCodeprivate AmetysObjectResolver _resolver
private BlogCacheManager _cacheManager
private I18nUtils _i18nUtils
private String _i18nCatalogue
private SiteConfigurationExtensionPoint _siteConf
private PagesContainer _root
private int _year
private SkinsManager _skinsManager
public VirtualYearPage(AmetysObjectResolver resolver, BlogCacheManager cacheManager, SkinsManager skinsManager, I18nUtils i18nCache, String i18nCatalogue, SiteConfigurationExtensionPoint siteConf, int year, String title, PagesContainer root)
resolver - the AmetysObjectResolver.cacheManager - the BlogCacheManager.skinsManager - the SkinsManageri18nCache - the i18n utilsi18nCatalogue - the i18n catalogue.siteConf - The site configurationyear - the yeartitle - the page's title.root - the blog root page.public int getYear()
public int getDepth() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.public Set<String> getReferers() throws AmetysRepositoryException
PageAmetysObject ids referencing this page.AmetysObject ids referencing this page.AmetysRepositoryException - if an error occurs.public ResourceCollection getRootAttachments() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.public String getTitle() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.public String getLongTitle() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.public String getURL() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.public Page.LinkType getURLType() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.protected Zone getDefaultZone()
AbstractBlogPagegetDefaultZone in class AbstractBlogPagepublic AmetysObjectIterable<? extends Page> getChildrenPages() throws AmetysRepositoryException
PagesContainerAmetysRepositoryException - if an error occurs.public AmetysObjectIterable<? extends Page> getChildrenPages(boolean includeInvisiblePages) throws AmetysRepositoryException
PagesContainerincludeInvisiblePages - true to include invisible pagesAmetysRepositoryException - if an error occurs.public Page getChildPageAt(int index) throws UnknownAmetysObjectException, AmetysRepositoryException
PagesContainerPage at the given positionindex - the position of the Page within the ordered set of its sibling objects.Page if foundUnknownAmetysObjectException - if no child page was found at this positionAmetysRepositoryException - if an error occurspublic String getPathInSitemap() throws AmetysRepositoryException
PagesContainerAmetysRepositoryException - if an error occurs.public Site getSite() throws AmetysRepositoryException
SiteAwareAmetysObjectAmetysRepositoryException - if an error occurs.public String getSiteName() throws AmetysRepositoryException
SiteAwareAmetysObjectAmetysRepositoryException - if an error occurs.public Sitemap getSitemap() throws AmetysRepositoryException
PagesContainerAmetysRepositoryException - if an error occurs.public String getSitemapName() throws AmetysRepositoryException
PagesContainerAmetysRepositoryException - if an error occurs.public <A extends AmetysObject> A getChild(String path) throws AmetysRepositoryException, UnknownAmetysObjectException
TraversableAmetysObjectnull, empty nor begin with a '/'.A - the actual type of AmetysObject.path - the path of the child which can contains a position with.
[n] if same name sibling is allowed.AmetysRepositoryException - if an error occurs.UnknownAmetysObjectException - if the object does not exist.public AmetysObjectIterable<? extends AmetysObject> getChildren() throws AmetysRepositoryException
TraversableAmetysObjectAmetysObjectIterable.AmetysRepositoryException - if an error occurs.public boolean hasChild(String name) throws AmetysRepositoryException
TraversableAmetysObjectname - the name to test. Cannot be null nor empty nor
begin with a '/' and it cannot contain '/'.true if the named child exists,
false otherwise.AmetysRepositoryException - if an error occurs.public String getId() throws AmetysRepositoryException
AmetysObject<protocol>://<protocol-specific-part>AmetysRepositoryException - if an error occurs.public String getName() throws AmetysRepositoryException
AmetysObjectAmetysRepositoryException - if an error occurs.public PagesContainer getParent() throws AmetysRepositoryException
AmetysObjectnull if current object
is the root.AmetysRepositoryException - if an error occurs.public String getParentPath() throws AmetysRepositoryException
AmetysObjectAmetysRepositoryException - if an error occurs.public String getPath() throws AmetysRepositoryException
AmetysObjectAmetysRepositoryException - if an error occurs.public CompositeMetadata getMetadataHolder()
MetadataAwareAmetysObjectCompositeMetadata of this AmetysObject.CompositeMetadata of this AmetysObjectpublic Set<String> getTags() throws AmetysRepositoryException
TagAwareAmetysObjectAmetysRepositoryException - if an error occurs.public String getTemplate() throws AmetysRepositoryException
PagegetTemplate in interface PagegetTemplate in class AbstractBlogPagenull if none has
been set.AmetysRepositoryException - if an error occurs.public boolean isVisible() throws AmetysRepositoryException
PageAmetysRepositoryException - if an error occurs.