Class Content
Class representing a Content asset in Commerce Cloud Digital.
Property Summary
Property Description ID : String (read-only)Returns the ID of the content asset. classificationFolder : Folder (read-only)Returns the Folder associated with this Content. description : String (read-only)Returns the description in the current locale or null. folders : Collection (read-only)Returns all folders to which this content is assigned. name : String (read-only)Returns the name of the content asset. online : Boolean (read-only)Returns the online status of the content. onlineFlag : Boolean (read-only)Returns the online status flag of the content. page : Boolean (read-only)Returns if the content is a Page or not. pageDescription : String (read-only)Returns the page description for the content in the current locale or null if there is no page description. pageKeywords : String (read-only)Returns the page keywords for the content in the current locale or null if there is no page title. pageMetaTags : Array (read-only)Returns all page meta tags, defined for this instance for which content can be generated. pageTitle : String (read-only)Returns the page title for the content in the current locale or null if there is no page title. pageURL : String (read-only)Returns the page URL for the content in the current locale or null if there is no page URL. searchable : Boolean (read-only)Returns the search status of the content. searchableFlag : Boolean (read-only)Returns the online status flag of the content. siteMapChangeFrequency : String (read-only)Returns the contents change frequency needed for the sitemap creation. siteMapIncluded : Number (read-only)Returns the status if the content is included into the sitemap. siteMapPriority : Number (read-only)Returns the contents priority needed for the sitemap creation. template : String (read-only)Returns the value of attribute ‘template’.
Constructor Summary
This class does not have a constructor, so you cannot create it directly.
Method Summary
Method Description getClassificationFolder ()Returns the Folder associated with this Content. getDescription ()Returns the description in the current locale or null. getFolders ()Returns all folders to which this content is assigned. getID ()Returns the ID of the content asset. getName ()Returns the name of the content asset. getOnlineFlag ()Returns the online status flag of the content. getPageDescription ()Returns the page description for the content in the current locale or null if there is no page description. getPageKeywords ()Returns the page keywords for the content in the current locale or null if there is no page title. getPageMetaTag (String )Returns the page meta tag for the specified id. getPageMetaTags ()Returns all page meta tags, defined for this instance for which content can be generated. getPageTitle ()Returns the page title for the content in the current locale or null if there is no page title. getPageURL ()Returns the page URL for the content in the current locale or null if there is no page URL. getSearchableFlag ()Returns the online status flag of the content. getSiteMapChangeFrequency ()Returns the contents change frequency needed for the sitemap creation. getSiteMapIncluded ()Returns the status if the content is included into the sitemap. getSiteMapPriority ()Returns the contents priority needed for the sitemap creation. getTemplate ()Returns the value of attribute ‘template’. isOnline ()Returns the online status of the content. isPage ()Returns if the content is a Page or not. isSearchable ()Returns the search status of the content. toPage ()Converts the content into the Page representation if isPage() yields true.
Methods inherited from class ExtensibleObject
describe , getCustom
Methods inherited from class PersistentObject
getCreationDate , getLastModified , getUUID
Methods inherited from class Object
assign , create , create , defineProperties , defineProperty , entries , freeze , fromEntries , getOwnPropertyDescriptor , getOwnPropertyNames , getOwnPropertySymbols , getPrototypeOf , hasOwnProperty , is , isExtensible , isFrozen , isPrototypeOf , isSealed , keys , preventExtensions , propertyIsEnumerable , seal , setPrototypeOf , toLocaleString , toString , valueOf , values
Property Details
ID
ID: String (read-only)
Returns the ID of the content asset.
classificationFolder
classificationFolder: Folder (read-only)
Returns the Folder associated with this Content. The folder is
used to determine the classification of the content.
description
description: String (read-only)
Returns the description in the current locale or null.
folders
folders: Collection (read-only)
Returns all folders to which this content is assigned.
name
name: String (read-only)
Returns the name of the content asset.
online
online: Boolean (read-only)
Returns the online status of the content.
onlineFlag
onlineFlag: Boolean (read-only)
Returns the online status flag of the content.
page
page: Boolean (read-only)
Returns if the content is a Page or not.
pageDescription
pageDescription: String (read-only)
Returns the page description for the content in the current locale
or null if there is no page description.
pageKeywords
pageKeywords: String (read-only)
Returns the page keywords for the content in the current locale
or null if there is no page title.
pageMetaTags
pageMetaTags: Array (read-only)
Returns all page meta tags, defined for this instance for which content can be generated.
The meta tag content is generated based on the content detail page meta tag context and rules.
The rules are obtained from the current content or inherited from the default folder,
up to the root folder.
pageTitle
pageTitle: String (read-only)
Returns the page title for the content in the current locale
or null if there is no page title.
pageURL
pageURL: String (read-only)
Returns the page URL for the content in the current locale
or null if there is no page URL.
searchable
searchable: Boolean (read-only)
Returns the search status of the content.
searchableFlag
searchableFlag: Boolean (read-only)
Returns the online status flag of the content.
siteMapChangeFrequency
siteMapChangeFrequency: String (read-only)
Returns the contents change frequency needed for the sitemap creation.
siteMapIncluded
siteMapIncluded: Number (read-only)
Returns the status if the content is included into the sitemap.
siteMapPriority
siteMapPriority: Number (read-only)
Returns the contents priority needed for the sitemap creation.
If no priority is defined, the method returns 0.0.
template
template: String (read-only)
Returns the value of attribute 'template'.
Method Details
getClassificationFolder()
getClassificationFolder(): Folder
Returns the Folder associated with this Content. The folder is
used to determine the classification of the content.
Returns:
the classification Folder.
getDescription()
getDescription(): String
Returns the description in the current locale or null.
Returns:
the description in the current locale or null.
getFolders()
getFolders(): Collection
Returns all folders to which this content is assigned.
Returns:
Collection of Folder objects.
getID()
getID(): String
Returns the ID of the content asset.
Returns:
the ID of the content asset.
getName()
getName(): String
Returns the name of the content asset.
Returns:
the name of the content asset.
getOnlineFlag()
getOnlineFlag(): Boolean
Returns the online status flag of the content.
Returns:
true if the content is online, false otherwise.
getPageDescription()
getPageDescription(): String
Returns the page description for the content in the current locale
or null if there is no page description.
Returns:
the page description for the content in the current locale
or null if there is no page description.
getPageKeywords()
getPageKeywords(): String
Returns the page keywords for the content in the current locale
or null if there is no page title.
Returns:
the page keywords for the content in the current locale
or null if there is no page title.
getPageMetaTag(String)
getPageMetaTag(id: String ): PageMetaTag
Returns the page meta tag for the specified id.
The meta tag content is generated based on the content detail page meta tag context and rule.
The rule is obtained from the current content or inherited from the default folder,
up to the root folder.
Null will be returned if the meta tag is undefined on the current instance, or if no rule can be found for the
current context, or if the rule resolves to an empty string.
Parameters:
id - the ID to get the page meta tag for
Returns:
page meta tag containing content generated based on rules
getPageMetaTags()
getPageMetaTags(): Array
Returns all page meta tags, defined for this instance for which content can be generated.
The meta tag content is generated based on the content detail page meta tag context and rules.
The rules are obtained from the current content or inherited from the default folder,
up to the root folder.
Returns:
page meta tags defined for this instance, containing content generated based on rules
getPageTitle()
getPageTitle(): String
Returns the page title for the content in the current locale
or null if there is no page title.
Returns:
the page title for the content in the current locale
or null if there is no page title.
getPageURL()
getPageURL(): String
Returns the page URL for the content in the current locale
or null if there is no page URL.
Returns:
the page URL for the content in the current locale
or null if there is no page URL.
getSearchableFlag()
getSearchableFlag(): Boolean
Returns the online status flag of the content.
Returns:
true if the content is searchable, false otherwise.
getSiteMapChangeFrequency()
getSiteMapChangeFrequency(): String
Returns the contents change frequency needed for the sitemap creation.
Returns:
The contents sitemap change frequency.
getSiteMapIncluded()
getSiteMapIncluded(): Number
Returns the status if the content is included into the sitemap.
Returns:
the value of the attribute 'siteMapIncluded'
getSiteMapPriority()
getSiteMapPriority(): Number
Returns the contents priority needed for the sitemap creation.
If no priority is defined, the method returns 0.0.
Returns:
The contents sitemap priority.
getTemplate()
getTemplate(): String
Returns the value of attribute 'template'.
Returns:
the value of the attribute 'template'
isOnline()
isOnline(): Boolean
Returns the online status of the content.
Returns:
true if the content is online, false otherwise.
isPage()
isPage(): Boolean
Returns if the content is a Page or not.
Returns:
true if the content is a Page , false otherwise.
isSearchable()
isSearchable(): Boolean
Returns the search status of the content.
Returns:
true if the content is searchable, false otherwise.
toPage()
toPage(): Page
Converts the content into the Page representation if isPage() yields true.
Returns:
the Page representation of the content if it is a page, null otherwise.
See Also: