Package org.apache.cxf.attachment

# Class AttachmentDeserializer

java.lang.Object
org.apache.cxf.attachment.AttachmentDeserializer

public class AttachmentDeserializer extends Object

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `ATTACHMENT_DIRECTORY`
  Allowed value is any instance of `File` or `String`.
  `static final String`
  `ATTACHMENT_MAX_COUNT`
  The maximum number of attachments permitted in a message.
  `static final String`
  `ATTACHMENT_MAX_HEADER_SIZE`
  The maximum MIME Header Length.
  `static final String`
  `ATTACHMENT_MAX_SIZE`
  The maximum size of the attachment.
  `static final String`
  `ATTACHMENT_MEMORY_THRESHOLD`
  The memory threshold of attachments.
  `static final String`
  `ATTACHMENT_PART_HEADERS`
  `static final int`
  `DEFAULT_MAX_HEADER_SIZE`
  `static final int`
  `THRESHOLD`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AttachmentDeserializer(Message message)`
  `AttachmentDeserializer(Message message, List<String> supportedTypes)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `hasNext()`
  Check for more attachment.
  `void`
  `initializeAttachments()`
  `protected void`
  `initializeRootMessage()`
  `boolean`
  `isLazyLoading()`
  `void`
  `markClosed(DelegatingInputStream delegatingInputStream)`
  `AttachmentImpl`
  `readNext()`
  `void`
  `setLazyLoading(boolean lazyLoading)`

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

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

- ## Field Details

  - ### ATTACHMENT_PART_HEADERS

    public static final String ATTACHMENT_PART_HEADERS

  - ### ATTACHMENT_DIRECTORY

    public static final String ATTACHMENT_DIRECTORY
    Allowed value is any instance of `File` or `String`.
    See Also:
      - Constant Field Values

  - ### ATTACHMENT_MEMORY_THRESHOLD

    public static final String ATTACHMENT_MEMORY_THRESHOLD
    The memory threshold of attachments. Allowed value is any instance of `Number` or `String`. The default is `THRESHOLD`.
    See Also:
      - Constant Field Values

  - ### ATTACHMENT_MAX_SIZE

    public static final String ATTACHMENT_MAX_SIZE
    The maximum size of the attachment. Allowed value is any of `Number` or `String`.
    See Also:
      - Constant Field Values

  - ### ATTACHMENT_MAX_COUNT

    public static final String ATTACHMENT_MAX_COUNT
    The maximum number of attachments permitted in a message. The default is 50.
    See Also:
      - Constant Field Values

  - ### ATTACHMENT_MAX_HEADER_SIZE

    public static final String ATTACHMENT_MAX_HEADER_SIZE
    The maximum MIME Header Length. The default is 300.
    See Also:
      - Constant Field Values

  - ### DEFAULT_MAX_HEADER_SIZE

    public static final int DEFAULT_MAX_HEADER_SIZE

  - ### THRESHOLD

    public static final int THRESHOLD
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### AttachmentDeserializer

    public AttachmentDeserializer(Message message)

  - ### AttachmentDeserializer

    public AttachmentDeserializer(Message message, List<String> supportedTypes)

- ## Method Details

  - ### initializeAttachments

    public void initializeAttachments() throws IOException
    Throws:
      `IOException`

  - ### initializeRootMessage

    protected void initializeRootMessage() throws IOException
    Throws:
      `IOException`

  - ### readNext

    public AttachmentImpl readNext() throws IOException
    Throws:
      `IOException`

  - ### isLazyLoading

    public boolean isLazyLoading()

  - ### setLazyLoading

    public void setLazyLoading(boolean lazyLoading)

  - ### markClosed

    public void markClosed(DelegatingInputStream delegatingInputStream) throws IOException
    Throws:
      `IOException`

  - ### hasNext

    public boolean hasNext() throws IOException
    Check for more attachment.
    Returns:
      whether there is more attachment or not. It will not deserialize the next attachment.
    Throws:
      `IOException`