Class: Postio::Models::Performance

Inherits:
Data
  • Object
show all
Defined in:
lib/postio/models.rb

Overview

Performance — per-request timing breakdown.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#lookup_msObject (readonly)

Returns the value of attribute lookup_ms

Returns:

  • (Object)

    the current value of lookup_ms



6
7
8
# File 'lib/postio/models.rb', line 6

def lookup_ms
  @lookup_ms
end

#worker_msObject (readonly)

Returns the value of attribute worker_ms

Returns:

  • (Object)

    the current value of worker_ms



6
7
8
# File 'lib/postio/models.rb', line 6

def worker_ms
  @worker_ms
end

Class Method Details

.from_hash(h) ⇒ Object



7
8
9
# File 'lib/postio/models.rb', line 7

def self.from_hash(h)
  new(worker_ms: h["workerMs"].to_i, lookup_ms: h["lookupMs"].to_i)
end