public CreateEventSubscriptionRequest withEventCategories(String... eventCategories) {
        if (this.eventCategories == null) {
            setEventCategories(new com.amazonaws.internal.SdkInternalList<String>(eventCategories.length));
        }
        for (String ele : eventCategories) {
            this.eventCategories.add(ele);
        }
        return this;
    }
<p>
A list of event categories for a particular source type (<code>SourceType</code>) that you want to subscribe to.
You can see a list of the categories for a given source type in the
"Amazon RDS event categories and event messages" section of the <a
href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.Messages.html"> <i>Amazon RDS User
Guide</i> </a> or the <a
href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Events.Messages.html"> <i>Amazon Aurora
User Guide</i> </a>. You can also see this list by using the <code>DescribeEventCategories</code> operation.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setEventCategories(java.util.Collection)} or {@link #withEventCategories(java.util.Collection)} if you
want to override the existing values.
</p>

@param eventCategories
       A list of event categories for a particular source type (<code>SourceType</code>) that you want to
       subscribe to. You can see a list of the categories for a given source type in the
       "Amazon RDS event categories and event messages" section of the <a
       href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.Messages.html"> <i>Amazon RDS
       User Guide</i> </a> or the <a
       href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Events.Messages.html"> <i>Amazon
       Aurora User Guide</i> </a>. You can also see this list by using the <code>DescribeEventCategories</code>
       operation.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-rds/src/main/java/com/amazonaws/services/rds/model/CreateEventSubscriptionRequest.java