Method: Wavefront::Validators#wf_distribution_values?

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

#wf_distribution_values?(vals) ⇒ Boolean

Validate an array of distribution values

Parameters:

Returns:

  • (Boolean)

    true if valid

Raises:

  • whichever exception is thrown first when validating each component of the distribution.



478
479
480
481
482
483
484
# File 'lib/wavefront-sdk/validators.rb', line 478

def wf_distribution_values?(vals)
  vals.each do |times, val|
    wf_distribution_count?(times)
    wf_value?(val)
  end
  true
end