Package org.apache.sling.cms
Interface PublishableResource
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.apache.sling.api.resource.ResourcegetContentResource()Retrieves the content Resource of the contentCalendargetCreated()Gets the date the content was createdStringgetCreatedBy()Gets the name of the user whom created this fileCalendargetLastModified()Gets the last time this file was modifiedStringgetLastModifiedBy()Gets the username of the user who last modified the contentCalendargetLastPublication()Gets the date of the last publication actionStringgetLastPublicationBy()Get the name of the user who last published the page.PublicationTypegetLastPublicationType()The last publication action typeStringgetName()Gets the name of the Sling Resource backing the contentorg.apache.sling.api.resource.ResourcegetParent()Gets the parent of the current page.StringgetPath()Get the path this page resides within the repositoryorg.apache.sling.api.resource.ValueMapgetProperties()Gets a ValueMap of the properties of the content resource for this pageStringgetPublishedPath()Gets the path of this page after it is published on the site's primary domain with the the html extensionStringgetPublishedUrl()Gets the full url (including domain) of this page after it is published on the site's primary domain with the the html extensionorg.apache.sling.api.resource.ResourcegetResource()Gets the resource backing this fileSitegetSite()Gets the site this file is contained withinbooleanisPublished()Returns true if the content is published, false otherwise
-
-
-
Method Detail
-
getPublishedPath
String getPublishedPath()
Gets the path of this page after it is published on the site's primary domain with the the html extension- Returns:
- the published path of the content
-
getPublishedUrl
String getPublishedUrl()
Gets the full url (including domain) of this page after it is published on the site's primary domain with the the html extension- Returns:
- the published url of the content
-
getSite
Site getSite()
Gets the site this file is contained within- Returns:
- the site containing the content
-
getContentResource
org.apache.sling.api.resource.Resource getContentResource()
Retrieves the content Resource of the content- Returns:
- the jcr:content child resource of the content
-
getCreated
Calendar getCreated()
Gets the date the content was created- Returns:
- the date on which the content was created
-
getCreatedBy
String getCreatedBy()
Gets the name of the user whom created this file- Returns:
- the name of the user whom created the content
-
getLastModified
Calendar getLastModified()
Gets the last time this file was modified- Returns:
- the date the content was last modified
-
getLastModifiedBy
String getLastModifiedBy()
Gets the username of the user who last modified the content- Returns:
- the name of the user who last modified the content
-
getLastPublicationType
PublicationType getLastPublicationType()
The last publication action type- Returns:
- the last publication type
-
getName
String getName()
Gets the name of the Sling Resource backing the content- Returns:
- the name of the content resource
-
getParent
org.apache.sling.api.resource.Resource getParent()
Gets the parent of the current page. This will generally be another sling:Page or sling:Site- Returns:
- the parent of the content, may not be another page
-
getPath
String getPath()
Get the path this page resides within the repository- Returns:
- the path of the content
-
getProperties
org.apache.sling.api.resource.ValueMap getProperties()
Gets a ValueMap of the properties of the content resource for this page- Returns:
- the properties of the content resource
-
isPublished
boolean isPublished()
Returns true if the content is published, false otherwise- Returns:
- whether or not the content is published
-
getResource
org.apache.sling.api.resource.Resource getResource()
Gets the resource backing this file- Returns:
- the resource backing the content
-
getLastPublication
Calendar getLastPublication()
Gets the date of the last publication action- Returns:
- the date of the publication action
-
getLastPublicationBy
String getLastPublicationBy()
Get the name of the user who last published the page.- Returns:
- the user name or null
-
-