Class ByteChunkDeferred


  • public class ByteChunkDeferred
    extends ByteChunk
    A Chunk that either acts as ByteChunk (if not initialized with a node) or lazy loads its binary data from the document (if linked with a node via readValue(DocumentNode)).
    • Constructor Detail

      • ByteChunkDeferred

        public ByteChunkDeferred​(String namePrefix,
                                 int chunkId,
                                 Types.MAPIType type)
        Creates a Byte Stream Chunk, with the specified type.
    • Method Detail

      • readValue

        public void readValue​(DocumentNode node)
        Links the chunk to a document
        Parameters:
        node - the document node
      • getValue

        public byte[] getValue()
        Get bytes directly.
        Overrides:
        getValue in class ByteChunk
      • setValue

        public void setValue​(byte[] value)
        Set bytes directly.

        updating the linked document node/msg file directly would be unexpected, so we remove the link and act as a ByteChunk from then

        Overrides:
        setValue in class ByteChunk