Class PageFieldImpl

java.lang.Object
org.broadleafcommerce.cms.page.domain.PageFieldImpl
All Implemented Interfaces:
Serializable, PageField, MultiTenantCloneable<PageField>, ProfileEntity

@Entity public class PageFieldImpl extends Object implements PageField, ProfileEntity
Created by bpolster.
See Also:
  • Field Details

    • id

      protected Long id
    • fieldKey

      protected String fieldKey
    • stringValue

      protected String stringValue
    • lobValue

      protected String lobValue
    • page

      protected Page page
  • Constructor Details

    • PageFieldImpl

      public PageFieldImpl()
  • Method Details

    • getId

      public Long getId()
      Specified by:
      getId in interface PageField
    • setId

      public void setId(Long id)
      Specified by:
      setId in interface PageField
    • getFieldKey

      public String getFieldKey()
      Specified by:
      getFieldKey in interface PageField
    • setFieldKey

      public void setFieldKey(String fieldKey)
      Specified by:
      setFieldKey in interface PageField
    • getValue

      public String getValue()
      Specified by:
      getValue in interface PageField
    • setValue

      public void setValue(String value)
      Specified by:
      setValue in interface PageField
    • getPage

      public Page getPage()
      Specified by:
      getPage in interface PageField
    • setPage

      public void setPage(Page page)
      Specified by:
      setPage in interface PageField
    • createOrRetrieveCopyInstance

      public <G extends PageField> 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();

      //copy extended field values on myClone here

      return createResponse; }

      Support should also be added for @Embeddable classes that contribute fields (collections or basic) to a cloneable entity:

      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 interface MultiTenantCloneable<PageField>
      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