public StreamSession withTruncatedEvents(StreamEvent... truncatedEvents) {
        if (this.truncatedEvents == null) {
            setTruncatedEvents(new java.util.ArrayList<StreamEvent>(truncatedEvents.length));
        }
        for (StreamEvent ele : truncatedEvents) {
            this.truncatedEvents.add(ele);
        }
        return this;
    }
<p>
List of Amazon IVS events that the stream encountered. The list is sorted by most recent events and contains up
to 500 events. For Amazon IVS events, see <a
href="https://docs.aws.amazon.com/ivs/latest/userguide/eventbridge.html">Using Amazon EventBridge with Amazon
IVS</a>.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setTruncatedEvents(java.util.Collection)} or {@link #withTruncatedEvents(java.util.Collection)} if you
want to override the existing values.
</p>

@param truncatedEvents
       List of Amazon IVS events that the stream encountered. The list is sorted by most recent events and
       contains up to 500 events. For Amazon IVS events, see <a
       href="https://docs.aws.amazon.com/ivs/latest/userguide/eventbridge.html">Using Amazon EventBridge with
       Amazon IVS</a>.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-ivs/src/main/java/com/amazonaws/services/ivs/model/StreamSession.java