Class: Google::Apis::ServicecontrolV2::Response
- Inherits:
-
Object
- Object
- Google::Apis::ServicecontrolV2::Response
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/servicecontrol_v2/classes.rb,
lib/google/apis/servicecontrol_v2/representations.rb,
lib/google/apis/servicecontrol_v2/representations.rb
Overview
This message defines attributes for a typical network response. It generally models semantics of an HTTP response.
Instance Attribute Summary collapse
-
#backend_latency ⇒ String
The amount of time it takes the backend service to fully respond to a request.
-
#code ⇒ Fixnum
The HTTP response status code, such as
200and404. -
#headers ⇒ Hash<String,String>
The HTTP response headers.
-
#size ⇒ Fixnum
The HTTP response size in bytes.
-
#time ⇒ String
The timestamp when the
destinationservice sends the last byte of the response.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Response
constructor
A new instance of Response.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Response
Returns a new instance of Response.
1053 1054 1055 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1053 def initialize(**args) update!(**args) end |
Instance Attribute Details
#backend_latency ⇒ String
The amount of time it takes the backend service to fully respond to a request.
Measured from when the destination service starts to send the request to the
backend until when the destination service receives the complete response from
the backend.
Corresponds to the JSON property backendLatency
1028 1029 1030 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1028 def backend_latency @backend_latency end |
#code ⇒ Fixnum
The HTTP response status code, such as 200 and 404.
Corresponds to the JSON property code
1033 1034 1035 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1033 def code @code end |
#headers ⇒ Hash<String,String>
The HTTP response headers. If multiple headers share the same key, they must
be merged according to HTTP spec. All header keys must be lowercased, because
HTTP header keys are case-insensitive.
Corresponds to the JSON property headers
1040 1041 1042 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1040 def headers @headers end |
#size ⇒ Fixnum
The HTTP response size in bytes. If unknown, it must be -1.
Corresponds to the JSON property size
1045 1046 1047 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1045 def size @size end |
#time ⇒ String
The timestamp when the destination service sends the last byte of the
response.
Corresponds to the JSON property time
1051 1052 1053 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1051 def time @time end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1058 1059 1060 1061 1062 1063 1064 |
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1058 def update!(**args) @backend_latency = args[:backend_latency] if args.key?(:backend_latency) @code = args[:code] if args.key?(:code) @headers = args[:headers] if args.key?(:headers) @size = args[:size] if args.key?(:size) @time = args[:time] if args.key?(:time) end |