MessageInterface
in
Table of Contents
Methods
- addSegment() : $this
- Add a segment to the message.
- addSegments() : $this
- Add multiple segments to the message.
- getAllSegments() : iterable<string|int, SegmentInterface>
- Get all the segments.
- getSegment() : SegmentInterface|null
- Get the first segment that matches the requested code.
- getSegments() : iterable<string|int, SegmentInterface>
- Get all the segments that match the requested code.
- serialize() : string
- Serialize all the segments added to this object.
Methods
addSegment()
Add a segment to the message.
public
addSegment(SegmentInterface $segment) : $this
Parameters
- $segment : SegmentInterface
Return values
$thisaddSegments()
Add multiple segments to the message.
public
addSegments(SegmentInterface ...$segments) : $this
Parameters
- $segments : SegmentInterface
Return values
$thisgetAllSegments()
Get all the segments.
public
getAllSegments() : iterable<string|int, SegmentInterface>
Return values
iterable<string|int, SegmentInterface>getSegment()
Get the first segment that matches the requested code.
public
getSegment(string $code) : SegmentInterface|null
Parameters
- $code : string
Return values
SegmentInterface|nullgetSegments()
Get all the segments that match the requested code.
public
getSegments(string $code) : iterable<string|int, SegmentInterface>
Parameters
- $code : string
Return values
iterable<string|int, SegmentInterface>serialize()
Serialize all the segments added to this object.
public
serialize() : string