Documentation ¶
Index ¶
- func GenerateRandomDokumentennummer() string
- func GenerateRandomNachrichtenReferenznummer() string
- func PruefidentifikatorInTransaktionsdatenValidation(sl validator.StructLevel)
- type BOneyComb
- func (boneyComb *BOneyComb) ContainsAny(typ botyp.BOTyp) bool
- func (boneyComb *BOneyComb) GetAbsender() *bo.Marktteilnehmer
- func (boneyComb *BOneyComb) GetAbsenderCode() *string
- func (boneyComb *BOneyComb) GetAll(typ botyp.BOTyp) bo.BusinessObjectSlice
- func (boneyComb *BOneyComb) GetDokumentennummer() *string
- func (boneyComb *BOneyComb) GetEmpfaenger() *bo.Marktteilnehmer
- func (boneyComb *BOneyComb) GetEmpfaengerCode() *string
- func (boneyComb *BOneyComb) GetMasterDataCount(typ botyp.BOTyp) uint
- func (boneyComb *BOneyComb) GetMasterDataCounts() map[botyp.BOTyp]uint
- func (boneyComb *BOneyComb) GetNachrichtenReferenznummer() *string
- func (boneyComb *BOneyComb) GetNachrichtendatum() (*time.Time, error)
- func (boneyComb *BOneyComb) GetPruefidentifikator() *string
- func (boneyComb *BOneyComb) GetSingle(typ botyp.BOTyp) (bo.BusinessObject, error)
- func (boneyComb *BOneyComb) GetTransactionData(key string) *string
- func (boneyComb *BOneyComb) GetTransaktionsdatenKeys() []string
- func (boneyComb *BOneyComb) SetAbsender(mt bo.Marktteilnehmer, useBo4eUri bool)
- func (boneyComb *BOneyComb) SetAbsenderCode(mpId string, useBo4eUri bool)
- func (boneyComb *BOneyComb) SetDokumentennummer(dokumentnummer string)
- func (boneyComb *BOneyComb) SetEmpfaenger(mt bo.Marktteilnehmer, useBo4eUri bool)
- func (boneyComb *BOneyComb) SetEmpfaengerCode(mpId string, useBo4eUri bool)
- func (boneyComb *BOneyComb) SetNachrichtenReferenznummer(referenzNummer string)
- func (boneyComb *BOneyComb) SetNachrichtendatum(nachrichtendatum time.Time)
- func (boneyComb *BOneyComb) SetPruefidentifikator(pruefi string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateRandomDokumentennummer ¶ added in v0.0.31
func GenerateRandomDokumentennummer() string
GenerateRandomDokumentennummer returns a random BGM key
func GenerateRandomNachrichtenReferenznummer ¶ added in v0.0.31
func GenerateRandomNachrichtenReferenznummer() string
GenerateRandomNachrichtenReferenznummer returns a random UNH key
func PruefidentifikatorInTransaktionsdatenValidation ¶ added in v0.0.17
func PruefidentifikatorInTransaktionsdatenValidation(sl validator.StructLevel)
PruefidentifikatorInTransaktionsdatenValidation returns true iff a valid Pruefidentifikator (see GetPruefidentifikator) is present
Types ¶
type BOneyComb ¶
type BOneyComb struct { Stammdaten bo.BusinessObjectSlice `json:"stammdaten" validate:"required"` // Stammdaten is an array of business objects Transaktionsdaten map[string]string `json:"transaktionsdaten" validate:"required"` // Transaktionsdaten are data relevant only in the context of this market communication message Links map[string][]string `json:"links"` // Links describes relations between different BusinessObjects in Stammdaten }
BOneyComb is a structure that is used when dealing with business objects that are embedded into market communication messages. The BOneyComb combines an array of business objects named "Stammdaten" with a key value dict of process data named "Transaktionsdaten"
func (*BOneyComb) ContainsAny ¶ added in v0.0.32
ContainsAny returns true if any business object of the given type is present in BOneyComb.Stammdaten
func (*BOneyComb) GetAbsender ¶
func (boneyComb *BOneyComb) GetAbsender() *bo.Marktteilnehmer
GetAbsender returns the sending bo.Marktteilnehmer if present in the Transaktionsdaten _and_ Stammdaten; nil otherwise
func (*BOneyComb) GetAbsenderCode ¶
GetAbsenderCode returns the 13 digit ID of the sending Marktteilnehmer if present in the Transaktionsdaten; nil otherwise
func (*BOneyComb) GetAll ¶ added in v0.0.32
func (boneyComb *BOneyComb) GetAll(typ botyp.BOTyp) bo.BusinessObjectSlice
GetAll returns all business objects from BOneyComb.Stammdaten that have the given type
func (*BOneyComb) GetDokumentennummer ¶
GetDokumentennummer returns the Dokumentennummer (BMG) from BOneyComb.Transaktionsdaten if it's present and nil otherwise
func (*BOneyComb) GetEmpfaenger ¶
func (boneyComb *BOneyComb) GetEmpfaenger() *bo.Marktteilnehmer
GetEmpfaenger returns the receiving bo.Marktteilnehmer if present in the Transaktionsdaten _and_ Stammdaten; nil otherwise
func (*BOneyComb) GetEmpfaengerCode ¶
GetEmpfaengerCode returns the 13 digit ID of the receiving Marktteilnehmer if present in both Transaktionsdaten; nil otherwise
func (*BOneyComb) GetMasterDataCount ¶ added in v0.0.30
GetMasterDataCount counts the objects of the given type in BOneyComb.Stammdaten
func (*BOneyComb) GetMasterDataCounts ¶ added in v0.0.30
GetMasterDataCounts counts the different object types in BOneyComb.Stammdaten
func (*BOneyComb) GetNachrichtenReferenznummer ¶ added in v0.0.31
GetNachrichtenReferenznummer returns the Dokumentennummer (UNH) from BOneyComb.Transaktionsdaten if it's present and nil otherwise
func (*BOneyComb) GetNachrichtendatum ¶
GetNachrichtendatum checks if the message date is present in BOneyComb.Transaktionsdaten, returns its value if it is present and nil otherwise. Returns an error iff the parsing fails
func (*BOneyComb) GetPruefidentifikator ¶ added in v0.0.17
GetPruefidentifikator returns the Pruefidentifikator from BOneyComb.Transaktionsdaten if it's present and nil otherwise
func (*BOneyComb) GetSingle ¶ added in v0.0.32
GetSingle returns the single present business object of the given type if it is present in BOneyComb.Stammdaten. It returns an error if there is none or more than one
func (*BOneyComb) GetTransactionData ¶
GetTransactionData checks if the key is present in BOneyComb.Transaktionsdaten, returns its value if it is present and nil otherwise
func (*BOneyComb) GetTransaktionsdatenKeys ¶ added in v0.0.30
GetTransaktionsdatenKeys returns a sorted array of keys used in the Transaktionsdaten This function is useful for unit testing purposes
func (*BOneyComb) SetAbsender ¶ added in v0.0.15
func (boneyComb *BOneyComb) SetAbsender(mt bo.Marktteilnehmer, useBo4eUri bool)
SetAbsender sets sending bo.Marktteilnehmer in both the Transaktionsdaten _and_ Stammdaten
func (*BOneyComb) SetAbsenderCode ¶ added in v0.0.15
SetAbsenderCode sets the 13 digit ID of the sending Marktteilnehmer in the Transaktionsdaten
func (*BOneyComb) SetDokumentennummer ¶ added in v0.0.16
SetDokumentennummer sets the Dokumentennummer (BGM) in the BOneyComb.Transaktionsdaten
func (*BOneyComb) SetEmpfaenger ¶ added in v0.0.15
func (boneyComb *BOneyComb) SetEmpfaenger(mt bo.Marktteilnehmer, useBo4eUri bool)
SetEmpfaenger sets receiving bo.Marktteilnehmer in both the Transaktionsdaten _and_ Stammdaten
func (*BOneyComb) SetEmpfaengerCode ¶ added in v0.0.15
SetEmpfaengerCode sets the 13 digit ID of the receiving Marktteilnehmer in the Transaktionsdaten
func (*BOneyComb) SetNachrichtenReferenznummer ¶ added in v0.0.31
SetNachrichtenReferenznummer sets the Reference Number (UNH) in the BOneyComb.Transaktionsdaten
func (*BOneyComb) SetNachrichtendatum ¶ added in v0.0.16
SetNachrichtendatum sets the nachrichtendatum in BOneyComb.Transaktionsdaten
func (*BOneyComb) SetPruefidentifikator ¶ added in v0.0.17
SetPruefidentifikator sets the Pruefidentifikator in the BOneyComb.Transaktionsdaten