Package com.helger.phase4.attachment
Class AS4OutgoingAttachment
java.lang.Object
com.helger.phase4.attachment.AS4OutgoingAttachment
This represents a single payload for an outgoing message.
- Since:
- 0.9.16
- Author:
- Philip Helger
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAS4OutgoingAttachment(@Nullable com.helger.base.array.bytes.ByteArrayWrapper aDataBytes, @Nullable File aDataFile, @Nullable String sContentID, @Nullable String sFilename, @NonNull com.helger.mime.IMimeType aMimeType, @Nullable EAS4CompressionMode eCompressionMode, @Nullable Charset aCharset, @Nullable com.helger.collection.commons.ICommonsOrderedMap<String, String> aCustomProperties) -
Method Summary
Modifier and TypeMethodDescriptionstatic @NonNull AS4OutgoingAttachment.Builderbuilder()Create a new builder.final @Nullable Charsetfinal @Nullable EAS4CompressionModefinal @Nullable Stringfinal @Nullable com.helger.base.array.bytes.ByteArrayWrapperfinal @Nullable Filefinal @Nullable Stringfinal @NonNull com.helger.mime.IMimeTypefinal booleanfinal booleantoString()
-
Constructor Details
-
AS4OutgoingAttachment
protected AS4OutgoingAttachment(@Nullable com.helger.base.array.bytes.ByteArrayWrapper aDataBytes, @Nullable File aDataFile, @Nullable String sContentID, @Nullable String sFilename, @NonNull com.helger.mime.IMimeType aMimeType, @Nullable EAS4CompressionMode eCompressionMode, @Nullable Charset aCharset, @Nullable com.helger.collection.commons.ICommonsOrderedMap<String, String> aCustomProperties)
-
-
Method Details
-
getDataBytes
public final @Nullable com.helger.base.array.bytes.ByteArrayWrapper getDataBytes()- Returns:
- The data to be send as a byte array. May be
nullin which casegetDataFile()has the content. - Since:
- 0.14.0
- See Also:
-
hasDataBytes
public final boolean hasDataBytes()- Returns:
trueif the data is available as a byte array,falseif it is a file.- See Also:
-
getDataFile
- Returns:
- The data to be send as a File. May be
nullin which casegetDataBytes()has the content. - Since:
- 0.14.0
- See Also:
-
hasDataFile
public final boolean hasDataFile()- Returns:
trueif the data is available as a File,falseif it is a byte array.- See Also:
-
getContentID
- Returns:
- The Content-ID to be used. May be
null.
-
getFilename
- Returns:
- The filename to be used. May be
null.
-
getMimeType
public final @NonNull com.helger.mime.IMimeType getMimeType()- Returns:
- The MIME type to be used. May not be
null.
-
getCompressionMode
- Returns:
- The compression mode to be used. May be
null.
-
getCharset
- Returns:
- The character set to use. May be
null. - Since:
- 0.14.0
-
customProperties
@ReturnsMutableObject public final @NonNull com.helger.collection.commons.ICommonsOrderedMap<String,String> customProperties()- Returns:
- All custom properties contained. Never
null. - Since:
- 2.8.6
-
getAllCustomProperties
@ReturnsMutableCopy public final @NonNull com.helger.collection.commons.ICommonsOrderedMap<String,String> getAllCustomProperties()- Returns:
- All custom properties contained. Never
null. - Since:
- 2.8.6
-
toString
-
builder
Create a new builder.- Returns:
- Never
null.
-