Skip to content

Commit

Permalink
Merge pull request #292 from beth-soptim/BDEWApplicationReference
Browse files Browse the repository at this point in the history
BDEWApplicationReference from RzÜ 2.3
  • Loading branch information
phax authored Dec 5, 2024
2 parents 52fff60 + b5450d0 commit 45a65ce
Showing 1 changed file with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,9 @@ protected WSS4JAttachment createMainAttachment (@Nonnull final AS4OutgoingAttach
if (m_aPayloadParams.getSubjectPartyRole () != null)
aPayloadAttachment.customPartProperties ()
.put ("BDEWSubjectPartyRole", m_aPayloadParams.getSubjectPartyRole ());
if (m_aPayloadParams.getApplicationReference () != null)
aPayloadAttachment.customPartProperties ()
.put ("BDEWApplicationReference", m_aPayloadParams.getApplicationReference ());
}
return aPayloadAttachment;
}
Expand Down Expand Up @@ -259,6 +262,7 @@ public static class BDEWPayloadParams
private LocalDate m_aFulfillmentDate;
private String m_sSubjectPartyID;
private String m_sSubjectPartyRole;
private String m_sApplicationReference;

/**
* @return BDEW payload document type for payload identifier
Expand Down Expand Up @@ -423,6 +427,31 @@ public BDEWPayloadParams setSubjectPartyRole (@Nullable final String sSubjectPar
return this;
}


/**
* @return BDEW payload application reference for payload identifier
* <code>BDEWApplicationReference</code>
*/
@Nullable
public String getApplicationReference ()
{
return m_sApplicationReference;
}

/**
* BDEW payload application reference
*
* @param sApplicationReference
* Application reference to use. May be <code>null</code>.
* @return this for chaining
*/
@Nonnull
public BDEWPayloadParams setApplicationReference (@Nullable final String sApplicationReference)
{
m_sApplicationReference = sApplicationReference;
return this;
}

@Override
public String toString ()
{
Expand All @@ -432,6 +461,7 @@ public String toString ()
.append ("FulfillmentDate", m_aFulfillmentDate)
.append ("SubjectPartyID", m_sSubjectPartyID)
.append ("SubjectPartyRole", m_sSubjectPartyRole)
.append ("ApplicationReference", m_sApplicationReference)
.getToString ();
}
}
Expand Down

0 comments on commit 45a65ce

Please sign in to comment.