Method: Wavefront::Validators#wf_metricspolicy_id?

Defined in:
lib/wavefront-sdk/validators.rb

#wf_metricspolicy_id?(id) ⇒ Boolean

Ensure the given argument is a valid Wavefront metrics policy ID

Parameters:

  • id (String)

    the metrics policy ID to validate

Returns:

  • (Boolean)

    true if the role ID is valid

Raises:

  • Wavefront::Exception::InvalidMetricsPolicyId if the ID is not valid



662
663
664
665
666
# File 'lib/wavefront-sdk/validators.rb', line 662

def wf_metricspolicy_id?(id)
  return true if uuid?(id)

  raise Wavefront::Exception::InvalidMetricsPolicyId, id
end