public GetOriginEndpointPolicyResult withPolicy(String policy) {
        setPolicy(policy);
        return this;
    }
<p>
The policy assigned to the origin endpoint.
</p>

@param policy
       The policy assigned to the origin endpoint.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-mediapackagev2/src/main/java/com/amazonaws/services/mediapackagev2/model/GetOriginEndpointPolicyResult.java