public RetrieveResult withResultItems(RetrieveResultItem... resultItems) {
        if (this.resultItems == null) {
            setResultItems(new java.util.ArrayList<RetrieveResultItem>(resultItems.length));
        }
        for (RetrieveResultItem ele : resultItems) {
            this.resultItems.add(ele);
        }
        return this;
    }
<p>
The results of the retrieved relevant passages for the search.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setResultItems(java.util.Collection)} or {@link #withResultItems(java.util.Collection)} if you want to
override the existing values.
</p>

@param resultItems
       The results of the retrieved relevant passages for the search.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-kendra/src/main/java/com/amazonaws/services/kendra/model/RetrieveResult.java