public NamedEntityDefinition withMetric(NamedEntityDefinitionMetric metric) {
        setMetric(metric);
        return this;
    }
<p>
The definition of a metric.
</p>

@param metric
       The definition of a metric.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-quicksight/src/main/java/com/amazonaws/services/quicksight/model/NamedEntityDefinition.java