Class AS4OutgoingAttachment

java.lang.Object
com.helger.phase4.attachment.AS4OutgoingAttachment

@Immutable public class AS4OutgoingAttachment extends Object
This represents a single payload for an outgoing message.
Since:
0.9.16
Author:
Philip Helger
  • Constructor Details

  • Method Details

    • getDataBytes

      @Nullable public final com.helger.commons.io.ByteArrayWrapper getDataBytes()
      Returns:
      The data to be send as a byte array. May be null in which case getDataFile() has the content.
      Since:
      0.14.0
      See Also:
    • hasDataBytes

      public final boolean hasDataBytes()
      Returns:
      true if the data is available as a byte array, false if it is a file.
      See Also:
    • getDataFile

      @Nullable public final File getDataFile()
      Returns:
      The data to be send as a File. May be null in which case getDataBytes() has the content.
      Since:
      0.14.0
      See Also:
    • hasDataFile

      public final boolean hasDataFile()
      Returns:
      true if the data is available as a File, false if it is a byte array.
      See Also:
    • getContentID

      @Nullable public final String getContentID()
      Returns:
      The Content-ID to be used. May be null.
    • getFilename

      @Nullable public final String getFilename()
      Returns:
      The filename to be used. May be null.
    • getMimeType

      @Nonnull public final com.helger.commons.mime.IMimeType getMimeType()
      Returns:
      The MIME type to be used. May not be null.
    • getCompressionMode

      @Nullable public final EAS4CompressionMode getCompressionMode()
      Returns:
      The compression mode to be used. May be null.
    • getCharset

      @Nullable public final Charset getCharset()
      Returns:
      The character set to use. May be null.
      Since:
      0.14.0
    • customProperties

      @Nonnull @ReturnsMutableObject public final com.helger.commons.collection.impl.ICommonsOrderedMap<String,String> customProperties()
      Returns:
      All custom properties contained. Never null.
      Since:
      2.8.6
    • getAllCustomProperties

      @Nonnull @ReturnsMutableCopy public final com.helger.commons.collection.impl.ICommonsOrderedMap<String,String> getAllCustomProperties()
      Returns:
      All custom properties contained. Never null.
      Since:
      2.8.6
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • builder

      @Nonnull public static AS4OutgoingAttachment.Builder builder()
      Create a new builder.
      Returns:
      Never null.