class Beaver::Resolution

Resolution Model.

Attributes

resolution_time[RW]

TODO: Write general description for this method @return [Integer]

type[RW]

TODO: Write general description for this method @return [Type5Enum]

Public Class Methods

from_hash(hash) click to toggle source

Creates an instance of the object from a hash.

# File lib/beaver/models/resolution.rb, line 32
def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  resolution_time = hash['resolution_time']
  type = hash['type']

  # Create object from extracted values.
  Resolution.new(resolution_time,
                 type)
end
names() click to toggle source

A mapping from model property names to API property names.

# File lib/beaver/models/resolution.rb, line 18
def self.names
  @_hash = {} if @_hash.nil?
  @_hash['resolution_time'] = 'resolution_time'
  @_hash['type'] = 'type'
  @_hash
end
new(resolution_time = nil, type = nil) click to toggle source
# File lib/beaver/models/resolution.rb, line 25
def initialize(resolution_time = nil,
               type = nil)
  @resolution_time = resolution_time
  @type = type
end