Class AbstractAS4Message<IMPLTYPE extends AbstractAS4Message<IMPLTYPE>>

java.lang.Object
com.helger.phase4.messaging.domain.AbstractAS4Message<IMPLTYPE>
Type Parameters:
IMPLTYPE - Real implementation type.
All Implemented Interfaces:
com.helger.commons.traits.IGenericImplTrait<IMPLTYPE>, IAS4Message
Direct Known Subclasses:
AS4ErrorMessage, AS4PullRequestMessage, AS4ReceiptMessage, AS4UserMessage

public abstract class AbstractAS4Message<IMPLTYPE extends AbstractAS4Message<IMPLTYPE>> extends Object implements IAS4Message, com.helger.commons.traits.IGenericImplTrait<IMPLTYPE>
Abstract AS4 message implementation
Author:
Philip Helger
  • Field Details

  • Constructor Details

  • Method Details

    • getSoapVersion

      @Nonnull public final ESoapVersion getSoapVersion()
      Specified by:
      getSoapVersion in interface IAS4Message
      Returns:
      The SOAP version to use. May not be null.
    • getMessageType

      @Nonnull public final EAS4MessageType getMessageType()
      Specified by:
      getMessageType in interface IAS4Message
      Returns:
      The type of the underlying message. Never null.
    • getMessagingID

      @Nonnull @Nonempty public final String getMessagingID()
      Specified by:
      getMessagingID in interface IAS4Message
      Returns:
      The ID of the "Messaging" element for referencing in signing. Should not be null. This is NOT the AS4 Message ID.
    • setMustUnderstand

      @Nonnull public final IMPLTYPE setMustUnderstand(boolean bMustUnderstand)
      Description copied from interface: IAS4Message
      Set the "mustUnderstand" value depending on the used SOAP version.
      Specified by:
      setMustUnderstand in interface IAS4Message
      Parameters:
      bMustUnderstand - true for must understand, false otherwise.
      Returns:
      this for chaining
    • getAsSoapDocument

      @Nonnull public final Document getAsSoapDocument(@Nullable Node aSoapBodyPayload)
      Description copied from interface: IAS4Message
      Create a SOAP document from this message with the specified optional payload. Attachments are not handled by this method.
      Specified by:
      getAsSoapDocument in interface IAS4Message
      Parameters:
      aSoapBodyPayload - The payload to be added into the SOAP body. May be null.
      Returns:
      The created DOM document.
    • toString

      public String toString()
      Overrides:
      toString in class Object