Class ContentCreate

java.lang.Object
io.github.primelib.confluence4j.rest.v1.models.ContentCreate

@Generated("io.github.primelib.primecodegen") public class ContentCreate extends Object
ContentCreate
  • Field Details

    • id

      protected String id
      The ID of the draft content. Required when publishing a draft.
    • title

      protected String title
    • type

      protected String type
      The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.
    • space

      protected Spacecc1E40 space
      The space that the content is being created in.
    • status

      protected String status
      The status of the new content.
    • container

      protected Map<String,Object> container
      The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.
    • ancestors

      protected List<Map<String,Object>> ancestors
      The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.
    • body

      protected Body5304Ad body
      The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.
  • Constructor Details

    • ContentCreate

      public ContentCreate(Consumer<ContentCreate> spec)
      Constructs a validated instance of ContentCreate.
      Parameters:
      spec - the specification to process
    • ContentCreate

      @Internal protected ContentCreate()
      Protected no-args constructor for use by serialization frameworks.
    • ContentCreate

      @Internal public ContentCreate(String id, String title, String type, Spacecc1E40 space, String status, Map<String,Object> container, List<Map<String,Object>> ancestors, Body5304Ad body)
      Constructs a validated instance of ContentCreate.

      NOTE: This constructor is not considered stable and may change if the model is updated. Consider using ContentCreate(Consumer) instead.

      Parameters:
      id - The ID of the draft content. Required when publishing a draft.
      title - title
      type - The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.
      space - The space that the content is being created in.
      status - The status of the new content.
      container - The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.
      ancestors - The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.
      body - The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.
  • Method Details

    • id

      public String id()
      Fluent getter for id.

      The ID of the draft content. Required when publishing a draft.

      Returns:
      id
    • id

      public ContentCreate id(String id)
      Fluent setter for id.

      The ID of the draft content. Required when publishing a draft.

      Parameters:
      id - id
      Returns:
      this
    • getId

      public String getId()
      Gets the value of id.

      The ID of the draft content. Required when publishing a draft.

      Returns:
      id
    • setId

      public void setId(String id)
      Sets the value of id.

      The ID of the draft content. Required when publishing a draft.

      Parameters:
      id - id
    • title

      public String title()
      Fluent getter for title.
      Returns:
      title
    • title

      public ContentCreate title(String title)
      Fluent setter for title.
      Parameters:
      title - title
      Returns:
      this
    • getTitle

      public String getTitle()
      Gets the value of title.
      Returns:
      title
    • setTitle

      public void setTitle(String title)
      Sets the value of title.
      Parameters:
      title - title
    • type

      public String type()
      Fluent getter for type.

      The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.

      Returns:
      type
    • type

      public ContentCreate type(String type)
      Fluent setter for type.

      The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.

      Parameters:
      type - type
      Returns:
      this
    • getType

      public String getType()
      Gets the value of type.

      The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.

      Returns:
      type
    • setType

      public void setType(String type)
      Sets the value of type.

      The type of the new content. Custom content types defined by apps are also supported. eg. 'page', 'blogpost', 'comment' etc.

      Parameters:
      type - type
    • space

      public Spacecc1E40 space()
      Fluent getter for space.

      The space that the content is being created in.

      Returns:
      space
    • space

      public ContentCreate space(Spacecc1E40 space)
      Fluent setter for space.

      The space that the content is being created in.

      Parameters:
      space - space
      Returns:
      this
    • getSpace

      public Spacecc1E40 getSpace()
      Gets the value of space.

      The space that the content is being created in.

      Returns:
      space
    • setSpace

      public void setSpace(Spacecc1E40 space)
      Sets the value of space.

      The space that the content is being created in.

      Parameters:
      space - space
    • status

      public String status()
      Fluent getter for status.

      The status of the new content.

      Returns:
      status
    • status

      public ContentCreate status(String status)
      Fluent setter for status.

      The status of the new content.

      Parameters:
      status - status
      Returns:
      this
    • getStatus

      public String getStatus()
      Gets the value of status.

      The status of the new content.

      Returns:
      status
    • setStatus

      public void setStatus(String status)
      Sets the value of status.

      The status of the new content.

      Parameters:
      status - status
    • container

      public Map<String,Object> container()
      Fluent getter for container.

      The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.

      Returns:
      container
    • container

      public ContentCreate container(Map<String,Object> container)
      Fluent setter for container.

      The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.

      Parameters:
      container - container
      Returns:
      this
    • getContainer

      public Map<String,Object> getContainer()
      Gets the value of container.

      The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.

      Returns:
      container
    • setContainer

      public void setContainer(Map<String,Object> container)
      Sets the value of container.

      The container of the content. Required if type is `comment` or certain types of custom content. If you are trying to create a comment that is a child of another comment, specify the parent comment in the ancestors field, not in this field.

      Parameters:
      container - container
    • ancestors

      public List<Map<String,Object>> ancestors()
      Fluent getter for ancestors.

      The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.

      Returns:
      ancestors
    • ancestors

      public ContentCreate ancestors(List<Map<String,Object>> ancestors)
      Fluent setter for ancestors.

      The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.

      Parameters:
      ancestors - ancestors
      Returns:
      this
    • getAncestors

      public List<Map<String,Object>> getAncestors()
      Gets the value of ancestors.

      The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.

      Returns:
      ancestors
    • setAncestors

      public void setAncestors(List<Map<String,Object>> ancestors)
      Sets the value of ancestors.

      The parent content of the new content. If you are creating a top-level `page` or `comment`, this can be left blank. If you are creating a child page, this is where the parent page id goes. If you are creating a child comment, this is where the parent comment id goes. Only one parent content id can be specified.

      Parameters:
      ancestors - ancestors
    • body

      public Body5304Ad body()
      Fluent getter for body.

      The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.

      Returns:
      body
    • body

      public ContentCreate body(Body5304Ad body)
      Fluent setter for body.

      The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.

      Parameters:
      body - body
      Returns:
      this
    • getBody

      public Body5304Ad getBody()
      Gets the value of body.

      The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.

      Returns:
      body
    • setBody

      public void setBody(Body5304Ad body)
      Sets the value of body.

      The body of the new content. Does not apply to attachments. Only one body format should be specified as the property for this object, e.g. `storage`. Note, `editor2` format is used by Atlassian only. `anonymous_export_view` is the same as `export_view` format but only content viewable by an anonymous user is included.

      Parameters:
      body - body
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object