-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbase_client.rbs
More file actions
135 lines (112 loc) · 4.06 KB
/
Copy pathbase_client.rbs
File metadata and controls
135 lines (112 loc) · 4.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
module DockerEngineRuby
module Internal
module Transport
class BaseClient
extend DockerEngineRuby::Internal::Util::SorbetRuntimeSupport
type request_components =
{
method: Symbol,
path: String | ::Array[String],
query: ::Hash[String, (::Array[String] | String)?]?,
headers: ::Hash[String, (String
| Integer
| ::Array[(String | Integer)?])?]?,
body: top?,
unwrap: (Symbol
| Integer
| ::Array[(Symbol | Integer)]
| (^(top arg0) -> top))?,
page: Class?,
stream: Class?,
model: DockerEngineRuby::Internal::Type::Converter::input?,
options: DockerEngineRuby::request_opts?
}
type request_input =
{
method: Symbol,
url: URI::Generic,
headers: ::Hash[String, String],
body: top,
max_retries: Integer,
timeout: Float
}
MAX_REDIRECTS: 20
PLATFORM_HEADERS: ::Hash[String, String]
def self.validate!: (
DockerEngineRuby::Internal::Transport::BaseClient::request_components req
) -> void
def self.should_retry?: (
Integer status,
headers: ::Hash[String, String]
) -> bool
def self.follow_redirect: (
DockerEngineRuby::Internal::Transport::BaseClient::request_input request,
status: Integer,
response_headers: ::Hash[String, String]
) -> DockerEngineRuby::Internal::Transport::BaseClient::request_input
def self.reap_connection!: (
Integer | DockerEngineRuby::Errors::APIConnectionError status,
stream: Enumerable[String]?
) -> void
attr_reader base_url: URI::Generic
attr_reader timeout: Float
attr_reader max_retries: Integer
attr_reader initial_retry_delay: Float
attr_reader max_retry_delay: Float
attr_reader headers: ::Hash[String, String]
attr_reader idempotency_header: String?
# @api private
attr_reader requester: DockerEngineRuby::Internal::Transport::PooledNetRequester
def initialize: (
base_url: String,
?timeout: Float,
?max_retries: Integer,
?initial_retry_delay: Float,
?max_retry_delay: Float,
?headers: ::Hash[String, (String
| Integer
| ::Array[(String | Integer)?])?],
?idempotency_header: String?,
?tls_verify_peer: bool,
?tls_ca_cert_path: String?,
?tls_client_cert_path: String?,
?tls_client_key_path: String?
) -> void
private def user_agent: -> String
private def generate_idempotency_key: -> String
private def build_request: (
DockerEngineRuby::Internal::Transport::BaseClient::request_components req,
DockerEngineRuby::request_options opts
) -> DockerEngineRuby::Internal::Transport::BaseClient::request_input
private def retry_delay: (
::Hash[String, String] headers,
retry_count: Integer
) -> Float
def send_request: (
DockerEngineRuby::Internal::Transport::BaseClient::request_input request,
redirect_count: Integer,
retry_count: Integer,
send_retry_header: bool
) -> [Integer, top, Enumerable[String]]
def request: (
Symbol method,
String | ::Array[String] path,
?query: ::Hash[String, (::Array[String] | String)?]?,
?headers: ::Hash[String, (String
| Integer
| ::Array[(String | Integer)?])?]?,
?body: top?,
?unwrap: (Symbol
| Integer
| ::Array[(Symbol | Integer)]
| (^(top arg0) -> top))?,
?page: Class?,
?stream: Class?,
?model: DockerEngineRuby::Internal::Type::Converter::input?,
?options: DockerEngineRuby::request_opts?
) -> top
def inspect: -> String
end
end
end
end