public EventSource withState(EventSourceState state) {
        this.state = state.toString();
        return this;
    }
<p>
The state of the event source. If it is ACTIVE, you have already created a matching event bus for this event
source, and that event bus is active. If it is PENDING, either you haven't yet created a matching event bus, or
that event bus is deactivated. If it is DELETED, you have created a matching event bus, but the event source has
since been deleted.
</p>

@param state
       The state of the event source. If it is ACTIVE, you have already created a matching event bus for this
       event source, and that event bus is active. If it is PENDING, either you haven't yet created a matching
       event bus, or that event bus is deactivated. If it is DELETED, you have created a matching event bus, but
       the event source has since been deleted.
@return Returns a reference to this object so that method calls can be chained together.
@see EventSourceState
aws-java-sdk-eventbridge/src/main/java/com/amazonaws/services/eventbridge/model/EventSource.java