Package com.independentsoft.graph

# Class AttachmentItem

java.lang.Object
com.independentsoft.graph.AttachmentItem

All Implemented Interfaces:
  `ICreatable`

public class AttachmentItem extends Object implements ICreatable

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AttachmentItem()`
  `AttachmentItem​(String filePath)`
  `AttachmentItem​(String name, AttachmentType type, long size)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getContentId()`
  `String`
  `getContentType()`
  `String`
  `getName()`
  `long`
  `getSize()`
  `AttachmentType`
  `getType()`
  `boolean`
  `isInline()`
  `void`
  `setAsInline​(boolean isInline)`
  `void`
  `setContentId​(String contentId)`
  `void`
  `setContentType​(String contentType)`
  `void`
  `setName​(String name)`
  `void`
  `setSize​(long size)`
  `void`
  `setType​(AttachmentType type)`
  `String`
  `toCreateJson()`
  Converts this object to its JSON representation for creation.
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### AttachmentItem

    public AttachmentItem()

  - ### AttachmentItem

    public AttachmentItem​(String filePath) throws IOException
    Throws:
      `IOException`

  - ### AttachmentItem

    public AttachmentItem​(String name, AttachmentType type, long size)

- ## Method Details

  - ### toCreateJson

    public String toCreateJson()
    Description copied from interface: `ICreatable`
    Converts this object to its JSON representation for creation.

    This method generates a JSON string containing all properties needed to create a new instance of this resource in Microsoft Graph. Only properties appropriate for creation should be included (e.g., excluding read-only properties like ID, createdTime, etc.).

    Specified by:
      `toCreateJson` in interface `ICreatable`
    Returns:
      JSON string representation for creating this resource

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`

  - ### getType

    public AttachmentType getType()

  - ### setType

    public void setType​(AttachmentType type)

  - ### getContentId

    public String getContentId()

  - ### setContentId

    public void setContentId​(String contentId)

  - ### getContentType

    public String getContentType()

  - ### setContentType

    public void setContentType​(String contentType)

  - ### isInline

    public boolean isInline()

  - ### setAsInline

    public void setAsInline​(boolean isInline)

  - ### getName

    public String getName()

  - ### setName

    public void setName​(String name)

  - ### getSize

    public long getSize()

  - ### setSize

    public void setSize​(long size)