Class OfferBase

    • Constructor Summary

      Constructors 
      Constructor Description
      OfferBase​(long id, java.lang.String name, java.lang.String content)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getContent()
      Returns the offer content, as set in Adobe Target
      java.lang.String getContentPath()
      Returns the path of this offer from the AEM repository
      long getId()
      Returns the offer id, as retrieved from Adobe Target
      MacMetadata getMacMetadata()
      Retrieves the metadata object attached to this offer reuquest.
      java.lang.String getName()
      Returns the name of the offer
      java.lang.String getType()
      Returns the offer type.
      java.lang.String getWorkspace()  
      void setMacMetadata​(MacMetadata metadata)
      Sets the metadata for this offer.
      void setType​(java.lang.String type)  
      void setWorkspace​(java.lang.String workspace)
      Optional id of workspace to which the offer belongs.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • OfferBase

        public OfferBase​(long id,
                         java.lang.String name,
                         java.lang.String content)
    • Method Detail

      • getName

        public java.lang.String getName()
        Returns the name of the offer
        Returns:
        a String object containing the offer name
      • getId

        public long getId()
        Returns the offer id, as retrieved from Adobe Target
        Returns:
        the id of the offer. If the offer hasn't been synchronized with Target this value is 0
      • getContentPath

        public java.lang.String getContentPath()
        Returns the path of this offer from the AEM repository
        Returns:
        the offer path
      • getContent

        public java.lang.String getContent()
        Returns the offer content, as set in Adobe Target
        Returns:
        the offer content. This is usually a callback to an AEM function which pulls the content from the repository
      • setMacMetadata

        public void setMacMetadata​(MacMetadata metadata)
        Sets the metadata for this offer.
        Parameters:
        metadata - a MacMetadata object. Note that the object must contain the mandatory metadata.
      • getMacMetadata

        public MacMetadata getMacMetadata()
        Retrieves the metadata object attached to this offer reuquest.
        Returns:
        a MacMetadata object
      • getType

        public java.lang.String getType()
        Returns the offer type.
        Returns:
        the offer type.
      • setType

        public void setType​(java.lang.String type)
        Parameters:
        type - offer type
      • getWorkspace

        public java.lang.String getWorkspace()
        Returns:
        the offer workspace id
      • setWorkspace

        public void setWorkspace​(java.lang.String workspace)
        Optional id of workspace to which the offer belongs. Max length is 250 characters. By default, Default workspace is assumed.
        Parameters:
        workspace - id of workspace