public DataSource withFailureReasons(String... failureReasons) {
        if (this.failureReasons == null) {
            setFailureReasons(new java.util.ArrayList<String>(failureReasons.length));
        }
        for (String ele : failureReasons) {
            this.failureReasons.add(ele);
        }
        return this;
    }
<p>
The detailed reasons on the failure to delete a data source.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setFailureReasons(java.util.Collection)} or {@link #withFailureReasons(java.util.Collection)} if you want
to override the existing values.
</p>

@param failureReasons
       The detailed reasons on the failure to delete a data source.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-bedrockagent/src/main/java/com/amazonaws/services/bedrockagent/model/DataSource.java