public GetMetricDataV2Request withEndTime(java.util.Date endTime) {
        setEndTime(endTime);
        return this;
    }
<p>
The timestamp, in UNIX Epoch time format, at which to end the reporting interval for the retrieval of historical
metrics data. The time must be later than the start time timestamp. It cannot be later than the current
timestamp.
</p>

@param endTime
       The timestamp, in UNIX Epoch time format, at which to end the reporting interval for the retrieval of
       historical metrics data. The time must be later than the start time timestamp. It cannot be later than the
       current timestamp.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-connect/src/main/java/com/amazonaws/services/connect/model/GetMetricDataV2Request.java