AbstractCmsService

AbstractCmsService ⇐ Abstract

Kind: global abstract class
Extends: Abstract
Service:

AbstractCmsService()

The CMS Service exposes the CMS Category Api

getCategories([options]) ⇒ Promise.<Array.<AbstractCmsCategory>, Error>

Retrieve the list of the root level categories

Kind: instance method of AbstractCmsService
Returns: Promise.<Array.<AbstractCmsCategory>, Error> - a list of cms categories

ParamTypeDefaultDescription
[options]Object

some options

[options.force]booleanfalse

If true, don't use the cache

[options.duration]number

Duration in milliseconds before invalidation of cache (if null, $$maxAge value is used by default)

getCategory(categoryId, [options]) ⇒ Promise.<AbstractCmsCategory, Error>

Retrieve a specific category by its id

Kind: instance method of AbstractCmsService

ParamTypeDefaultDescription
categoryIdstring

category id to get

[options]Object

some options

[options.force]booleanfalse

If true, don't use the cache

[options.duration]number

Duration in milliseconds before invalidation of cache (if null, $$maxAge value is used by default)

getContents(categoryId, [options]) ⇒ Promise.<ContentList, Error>

Retrieve contents of a given category id

Kind: instance method of AbstractCmsService

ParamTypeDefaultDescription
categoryIdstring

category id

[options]object

some options

[options.start]number

index of the first content to retrieve

[options.number]number

limit the number of content fetched

[options.force]booleanfalse

If true, don't use the cache

[options.duration]number

Duration in milliseconds before invalidation of cache (if null, $$maxAge value is used by default)

getContent(contentId, [options]) ⇒ Promise.<Content, Error>

Retrieve content details by it’s id

Kind: instance method of AbstractCmsService
Returns: Promise.<Content, Error> - Content details

ParamTypeDefaultDescription
contentIdstring

Id of a content

[options]Object

additional options

[options.force]booleanfalse

If true, don't use the cache

[options.duration]number

Duration in milliseconds before invalidation of cache (if null, $$maxAge value is used by default)

_getCategories([options]) ⇒ Promise.<Array.<AbstractCmsCategory>, Error>

Vendor implementation to get categories

Kind: instance abstract method of AbstractCmsService
Returns: Promise.<Array.<AbstractCmsCategory>, Error> - a list of cms categories
Access: protected

ParamTypeDefaultDescription
[options]Object

some options

[options.force]booleanfalse

If true, don't use the cache

_getCategory(categoryId, [options]) ⇒ Promise.<AbstractCmsCategory, Error>

Vendor implementation to retrieve a specific category by its id

Kind: instance abstract method of AbstractCmsService
Access: protected

ParamTypeDefaultDescription
categoryIdstring

category id to get

[options]Object

some options

[options.force]booleanfalse

If true, don't use the cache

_getContents(categoryId, [options]) ⇒ Promise.<ContentList, Error>

Vendor implementation to get contents for a given category

Kind: instance abstract method of AbstractCmsService
Access: protected

ParamTypeDefaultDescription
categoryIdstring

category id

[options]object

some options

[options.force]booleanfalse

If true, don't use the cache

_getContent(contentId, [options]) ⇒ Promise.<Content, Error>

Vendor implementation to get content detail for a given content id

Kind: instance abstract method of AbstractCmsService
Access: protected

ParamTypeDefaultDescription
contentIdstring

content id

[options]object

some options

[options.force]booleanfalse

If true, don't use the cache