class TicketflyPlus::Responses::Base
Attributes
link[RW]
maxResults[RW]
pageNum[RW]
status[RW]
title[RW]
totalPages[RW]
totalResults[RW]
Public Class Methods
new(response)
click to toggle source
# File lib/ticketfly_plus/responses.rb, line 15 def initialize(response) @link = response['link'] @maxResults = check_nil(response['maxResults']).to_i @pageNum = check_nil(response['pageNum']).to_i @status = response['status'] @title = response['title'] @totalPages = check_nil(response['totalPages']).to_i @totalResults = check_nil(response['totalResults']).to_i end
Private Instance Methods
check_nil(response)
click to toggle source
# File lib/ticketfly_plus/responses.rb, line 27 def check_nil(response) !response.nil? ? response : nil end