public DescribeAgentResult withEndpointType(EndpointType endpointType) {
        this.endpointType = endpointType.toString();
        return this;
    }
<p>
The type of <a href="https://docs.aws.amazon.com/datasync/latest/userguide/choose-service-endpoint.html">service
endpoint</a> that your agent is connected to.
</p>

@param endpointType
       The type of <a
       href="https://docs.aws.amazon.com/datasync/latest/userguide/choose-service-endpoint.html">service
       endpoint</a> that your agent is connected to.
@return Returns a reference to this object so that method calls can be chained together.
@see EndpointType
aws-java-sdk-datasync/src/main/java/com/amazonaws/services/datasync/model/DescribeAgentResult.java