Class PageImpl
java.lang.Object
org.broadleafcommerce.cms.page.domain.PageImpl
- All Implemented Interfaces:
Serializable
,Page
,PageAdminPresentation
,AdminMainEntity
,MultiTenantCloneable<Page>
,ProfileEntity
,Locatable
@Entity
public class PageImpl
extends Object
implements Page, AdminMainEntity, Locatable, ProfileEntity, PageAdminPresentation
Created by bpolster.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.broadleafcommerce.cms.page.domain.PageAdminPresentation
PageAdminPresentation.GroupName, PageAdminPresentation.GroupOrder, PageAdminPresentation.TabName, PageAdminPresentation.TabOrder
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Date
protected Date
protected Map<String,
PageAttribute> protected String
protected Boolean
protected String
protected Long
protected String
protected String
protected Boolean
Deprecated.protected PageTemplate
protected Integer
Deprecated.protected Set<PageItemCriteria>
Deprecated.Fields inherited from interface org.broadleafcommerce.common.admin.domain.AdminMainEntity
MAIN_ENTITY_NAME_PROPERTY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<G extends Page>
CreateResponse<G>Clone this entity for the purpose of multiple tenancy.boolean
Returns the excludeFromSiteMap flag.getId()
If this is returning something that is non-null, this MUST return a String that starts with a slash and does not end with a slash.Returns the offlineFlag.Returns a map of the targeting rules associated with this page.Gets the integer priority of this content item.Returns the item (or cart) based rules associated with this content item.void
setActiveEndDate
(Date activeEndDate) void
setActiveStartDate
(Date activeStartDate) void
setAdditionalAttributes
(Map<String, PageAttribute> additionalAttributes) void
setDescription
(String description) void
setExcludeFromSiteMap
(boolean excludeFromSiteMap) Sets the excludeFromSiteMap flag.void
setFullUrl
(String fullUrl) void
void
setMetaDescription
(String metaDescription) void
setMetaTitle
(String metaTitle) void
setOfflineFlag
(Boolean offlineFlag) Sets the offline flag.void
setPageFields
(Map<String, PageField> pageFields) void
setPageMatchRules
(Map<String, PageRule> pageMatchRules) Sets the targeting rules for this content item.void
setPageTemplate
(PageTemplate pageTemplate) void
setPriority
(Integer priority) Sets the display priority of this item.void
setQualifyingItemCriteria
(Set<PageItemCriteria> qualifyingItemCriteria) Sets the item (e.g. cart) based rules associated with this content item.
-
Field Details
-
id
-
pageTemplate
-
description
-
fullUrl
-
pageFields
-
priority
Deprecated. -
offlineFlag
-
pageMatchRules
Deprecated. -
qualifyingItemCriteria
Deprecated. -
excludeFromSiteMap
-
additionalAttributes
-
activeStartDate
-
activeEndDate
-
metaTitle
-
metaDescription
-
-
Constructor Details
-
PageImpl
public PageImpl()
-
-
Method Details
-
getId
-
setId
-
getPageTemplate
- Specified by:
getPageTemplate
in interfacePage
-
setPageTemplate
- Specified by:
setPageTemplate
in interfacePage
-
getPageFields
- Specified by:
getPageFields
in interfacePage
-
setPageFields
- Specified by:
setPageFields
in interfacePage
-
getFullUrl
- Specified by:
getFullUrl
in interfacePage
-
setFullUrl
- Specified by:
setFullUrl
in interfacePage
-
getDescription
- Specified by:
getDescription
in interfacePage
-
setDescription
- Specified by:
setDescription
in interfacePage
-
getOfflineFlag
Description copied from interface:Page
Returns the offlineFlag. True indicates that the page should no longer appear on the site. The item will still appear within the content administration program but no longer be returned as part of the client facing APIs.- Specified by:
getOfflineFlag
in interfacePage
- Returns:
- true if this item is offline
-
setOfflineFlag
Description copied from interface:Page
Sets the offline flag.- Specified by:
setOfflineFlag
in interfacePage
-
getPriority
Description copied from interface:Page
Gets the integer priority of this content item. Items with a lower priority should be displayed before items with a higher priority.- Specified by:
getPriority
in interfacePage
- Returns:
- the priority as a numeric value
-
setPriority
Description copied from interface:Page
Sets the display priority of this item. Lower priorities should be displayed first.- Specified by:
setPriority
in interfacePage
-
getPageMatchRules
Description copied from interface:Page
Returns a map of the targeting rules associated with this page.Targeting rules are defined in the content mangagement system and used to enforce which page is returned to the client.
- Specified by:
getPageMatchRules
in interfacePage
- Returns:
-
setPageMatchRules
Description copied from interface:Page
Sets the targeting rules for this content item.- Specified by:
setPageMatchRules
in interfacePage
-
getQualifyingItemCriteria
Description copied from interface:Page
Returns the item (or cart) based rules associated with this content item.- Specified by:
getQualifyingItemCriteria
in interfacePage
- Returns:
-
setQualifyingItemCriteria
Description copied from interface:Page
Sets the item (e.g. cart) based rules associated with this content item.- Specified by:
setQualifyingItemCriteria
in interfacePage
-
getExcludeFromSiteMap
public boolean getExcludeFromSiteMap()Description copied from interface:Page
Returns the excludeFromSiteMap flag. True indicates that the page should be excluded from the site map.- Specified by:
getExcludeFromSiteMap
in interfacePage
- Returns:
- true if this page is excluded from the site map
-
setExcludeFromSiteMap
public void setExcludeFromSiteMap(boolean excludeFromSiteMap) Description copied from interface:Page
Sets the excludeFromSiteMap flag.- Specified by:
setExcludeFromSiteMap
in interfacePage
-
createOrRetrieveCopyInstance
public <G extends Page> CreateResponse<G> createOrRetrieveCopyInstance(MultiTenantCopyContext context) throws CloneNotSupportedException Description copied from interface:MultiTenantCloneable
Clone this entity for the purpose of multiple tenancy. Note, extending classes should follow this pattern:public CreateResponse<MyClass> createOrRetrieveCopyInstance(MultiTenantCopyContext context) throws CloneNotSupportedException { CreateResponse<MyClass> createResponse = super.createOrRetrieveCopyInstance(context); if (createResponse.isAlreadyPopulated()) { return createResponse; } MyClass myClone = createResponse.getClone();
Support should also be added for @Embeddable classes that contribute fields (collections or basic) to a cloneable entity://copy extended field values on myClone here
return createResponse; }
public CreateResponse<G extends MyClass> createOrRetrieveCopyInstance(MultiTenantCopyContext context) throws CloneNotSupportedException { CreateResponse
createResponse = context.createOrRetrieveCopyInstance(this); MyClass myClone = createResponse.getClone(); //copy extended field values on myClone here
return createResponse; }
- Specified by:
createOrRetrieveCopyInstance
in interfaceMultiTenantCloneable<Page>
- Parameters:
context
- a context object providing persistence and library functionality for copying entities- Returns:
- the resulting copy container, possibly already persisted
- Throws:
CloneNotSupportedException
- if there's a problem detected with the cloning configuration
-
getMainEntityName
- Specified by:
getMainEntityName
in interfaceAdminMainEntity
- Returns:
- the display name of this entity for the admin screen
-
getLocation
Description copied from interface:Locatable
If this is returning something that is non-null, this MUST return a String that starts with a slash and does not end with a slash.- Specified by:
getLocation
in interfaceLocatable
- Returns:
- the url of the locatable item
-
getAdditionalAttributes
- Specified by:
getAdditionalAttributes
in interfacePage
-
setAdditionalAttributes
- Specified by:
setAdditionalAttributes
in interfacePage
-
getActiveStartDate
- Specified by:
getActiveStartDate
in interfacePage
-
setActiveStartDate
- Specified by:
setActiveStartDate
in interfacePage
-
getActiveEndDate
- Specified by:
getActiveEndDate
in interfacePage
-
setActiveEndDate
- Specified by:
setActiveEndDate
in interfacePage
-
getMetaTitle
- Specified by:
getMetaTitle
in interfacePage
-
setMetaTitle
- Specified by:
setMetaTitle
in interfacePage
-
getMetaDescription
- Specified by:
getMetaDescription
in interfacePage
-
setMetaDescription
- Specified by:
setMetaDescription
in interfacePage
-