Class: Notion::Transport::Response

Inherits:
Data
  • Object
show all
Defined in:
lib/notion/transport.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(status:, headers:, body:, request_id:, elapsed:, attempt: 1, retried: false) ⇒ Response

Returns a new instance of Response.



10
11
12
# File 'lib/notion/transport.rb', line 10

def initialize(status:, headers:, body:, request_id:, elapsed:, attempt: 1, retried: false)
  super
end

Instance Attribute Details

#attemptObject (readonly)

Returns the value of attribute attempt

Returns:

  • (Object)

    the current value of attempt



9
10
11
# File 'lib/notion/transport.rb', line 9

def attempt
  @attempt
end

#bodyObject (readonly)

Returns the value of attribute body

Returns:

  • (Object)

    the current value of body



9
10
11
# File 'lib/notion/transport.rb', line 9

def body
  @body
end

#elapsedObject (readonly)

Returns the value of attribute elapsed

Returns:

  • (Object)

    the current value of elapsed



9
10
11
# File 'lib/notion/transport.rb', line 9

def elapsed
  @elapsed
end

#headersObject (readonly)

Returns the value of attribute headers

Returns:

  • (Object)

    the current value of headers



9
10
11
# File 'lib/notion/transport.rb', line 9

def headers
  @headers
end

#request_idObject (readonly)

Returns the value of attribute request_id

Returns:

  • (Object)

    the current value of request_id



9
10
11
# File 'lib/notion/transport.rb', line 9

def request_id
  @request_id
end

#retriedObject (readonly)

Returns the value of attribute retried

Returns:

  • (Object)

    the current value of retried



9
10
11
# File 'lib/notion/transport.rb', line 9

def retried
  @retried
end

#statusObject (readonly)

Returns the value of attribute status

Returns:

  • (Object)

    the current value of status



9
10
11
# File 'lib/notion/transport.rb', line 9

def status
  @status
end