public GetResourceSharesResult withResourceShares(ResourceShare... resourceShares) {
        if (this.resourceShares == null) {
            setResourceShares(new java.util.ArrayList<ResourceShare>(resourceShares.length));
        }
        for (ResourceShare ele : resourceShares) {
            this.resourceShares.add(ele);
        }
        return this;
    }
<p>
An array of objects that contain the information about the resource shares.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setResourceShares(java.util.Collection)} or {@link #withResourceShares(java.util.Collection)} if you want
to override the existing values.
</p>

@param resourceShares
       An array of objects that contain the information about the resource shares.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-ram/src/main/java/com/amazonaws/services/ram/model/GetResourceSharesResult.java