acts-as-messageable 0.5.0 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/dependabot.yml +8 -0
- data/.github/workflows/test.yml +152 -0
- data/.rubocop.yml +14 -1
- data/.rubocop_todo.yml +49 -7
- data/.ruby-version +1 -0
- data/Appraisals +11 -0
- data/Dockerfile +2 -1
- data/Gemfile +19 -13
- data/Gemfile.lock +186 -97
- data/README.md +2 -3
- data/Rakefile +6 -1
- data/VERSION +1 -1
- data/acts-as-messageable.gemspec +193 -40
- data/bin/tapioca +29 -0
- data/docker-compose.yml +82 -71
- data/gemfiles/rails_3.2.gemfile +14 -9
- data/gemfiles/rails_4.2.gemfile +14 -9
- data/gemfiles/rails_5.2.gemfile +14 -9
- data/gemfiles/rails_6.0.gemfile +14 -9
- data/gemfiles/rails_7.0.gemfile +29 -0
- data/gemfiles/rails_master.gemfile +15 -9
- data/lib/acts-as-messageable.rb +1 -0
- data/lib/acts_as_messageable/message.rb +62 -5
- data/lib/acts_as_messageable/model.rb +71 -20
- data/lib/acts_as_messageable/rails3.rb +27 -2
- data/lib/acts_as_messageable/rails4.rb +31 -4
- data/lib/acts_as_messageable/rails6.rb +34 -2
- data/lib/acts_as_messageable/railtie.rb +1 -0
- data/lib/acts_as_messageable/relation.rb +18 -2
- data/lib/acts_as_messageable/scopes.rb +11 -0
- data/lib/acts_as_messageable.rb +18 -0
- data/lib/generators/acts_as_messageable/migration/migration_generator.rb +4 -0
- data/lib/generators/acts_as_messageable/migration/templates/migration.rb +1 -0
- data/lib/generators/acts_as_messageable/migration/templates/migration_indexes.rb +1 -0
- data/lib/generators/acts_as_messageable/migration/templates/migration_opened_as_datetime.rb +1 -0
- data/lib/generators/acts_as_messageable/migration/templates/migration_permanent.rb +1 -0
- data/sorbet/config +4 -0
- data/sorbet/rbi/annotations/actionpack.rbi +428 -0
- data/sorbet/rbi/annotations/actionview.rbi +77 -0
- data/sorbet/rbi/annotations/activerecord.rbi +18 -0
- data/sorbet/rbi/annotations/activesupport.rbi +52 -0
- data/sorbet/rbi/annotations/faraday.rbi +17 -0
- data/sorbet/rbi/annotations/railties.rbi +58 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/dsl/abstract_controller/caching/fragments.rbi +23 -0
- data/sorbet/rbi/dsl/abstract_controller/caching.rbi +30 -0
- data/sorbet/rbi/dsl/abstract_controller/callbacks.rbi +23 -0
- data/sorbet/rbi/dsl/abstract_controller/helpers.rbi +23 -0
- data/sorbet/rbi/dsl/abstract_controller/rendering.rbi +9 -0
- data/sorbet/rbi/dsl/abstract_controller/url_for.rbi +23 -0
- data/sorbet/rbi/dsl/action_controller/caching.rbi +29 -0
- data/sorbet/rbi/dsl/action_controller/conditional_get.rbi +23 -0
- data/sorbet/rbi/dsl/action_controller/content_security_policy.rbi +31 -0
- data/sorbet/rbi/dsl/action_controller/data_streaming.rbi +9 -0
- data/sorbet/rbi/dsl/action_controller/etag_with_flash.rbi +24 -0
- data/sorbet/rbi/dsl/action_controller/etag_with_template_digest.rbi +30 -0
- data/sorbet/rbi/dsl/action_controller/flash.rbi +19 -0
- data/sorbet/rbi/dsl/action_controller/form_builder.rbi +19 -0
- data/sorbet/rbi/dsl/action_controller/helpers.rbi +36 -0
- data/sorbet/rbi/dsl/action_controller/params_wrapper.rbi +23 -0
- data/sorbet/rbi/dsl/action_controller/redirecting.rbi +24 -0
- data/sorbet/rbi/dsl/action_controller/renderers/all.rbi +24 -0
- data/sorbet/rbi/dsl/action_controller/renderers.rbi +23 -0
- data/sorbet/rbi/dsl/action_controller/request_forgery_protection.rbi +31 -0
- data/sorbet/rbi/dsl/action_controller/rescue.rbi +24 -0
- data/sorbet/rbi/dsl/action_controller/test_case/behavior.rbi +24 -0
- data/sorbet/rbi/dsl/action_controller/url_for.rbi +24 -0
- data/sorbet/rbi/dsl/action_dispatch/routing/url_for.rbi +23 -0
- data/sorbet/rbi/dsl/action_view/helpers/form_helper.rbi +10 -0
- data/sorbet/rbi/dsl/action_view/helpers/form_tag_helper.rbi +10 -0
- data/sorbet/rbi/dsl/action_view/helpers/text_helper.rbi +9 -0
- data/sorbet/rbi/dsl/action_view/helpers.rbi +10 -0
- data/sorbet/rbi/dsl/action_view/layouts.rbi +24 -0
- data/sorbet/rbi/dsl/action_view/rendering.rbi +9 -0
- data/sorbet/rbi/dsl/active_model/attribute_methods.rbi +27 -0
- data/sorbet/rbi/dsl/active_model/attributes.rbi +34 -0
- data/sorbet/rbi/dsl/active_model/dirty.rbi +28 -0
- data/sorbet/rbi/dsl/active_model/serializers/json.rbi +22 -0
- data/sorbet/rbi/dsl/active_model/validations/callbacks.rbi +22 -0
- data/sorbet/rbi/dsl/active_model/validations.rbi +27 -0
- data/sorbet/rbi/dsl/active_record/attribute_methods/dirty.rbi +38 -0
- data/sorbet/rbi/dsl/active_record/attribute_methods/time_zone_conversion.rbi +32 -0
- data/sorbet/rbi/dsl/active_record/attribute_methods.rbi +53 -0
- data/sorbet/rbi/dsl/active_record/attributes.rbi +19 -0
- data/sorbet/rbi/dsl/active_record/callbacks.rbi +22 -0
- data/sorbet/rbi/dsl/active_record/core.rbi +55 -0
- data/sorbet/rbi/dsl/active_record/encryption/encryptable_record.rbi +23 -0
- data/sorbet/rbi/dsl/active_record/inheritance.rbi +27 -0
- data/sorbet/rbi/dsl/active_record/integration.rbi +32 -0
- data/sorbet/rbi/dsl/active_record/locking/optimistic.rbi +22 -0
- data/sorbet/rbi/dsl/active_record/model_schema.rbi +52 -0
- data/sorbet/rbi/dsl/active_record/nested_attributes.rbi +22 -0
- data/sorbet/rbi/dsl/active_record/readonly_attributes.rbi +19 -0
- data/sorbet/rbi/dsl/active_record/reflection.rbi +32 -0
- data/sorbet/rbi/dsl/active_record/scoping/default.rbi +23 -0
- data/sorbet/rbi/dsl/active_record/scoping.rbi +23 -0
- data/sorbet/rbi/dsl/active_record/serialization.rbi +22 -0
- data/sorbet/rbi/dsl/active_record/signed_id.rbi +22 -0
- data/sorbet/rbi/dsl/active_record/test_fixtures.rbi +58 -0
- data/sorbet/rbi/dsl/active_record/timestamp.rbi +23 -0
- data/sorbet/rbi/dsl/active_record/validations.rbi +28 -0
- data/sorbet/rbi/dsl/active_support/actionable_error.rbi +23 -0
- data/sorbet/rbi/dsl/active_support/callbacks.rbi +22 -0
- data/sorbet/rbi/dsl/active_support/rescuable.rbi +23 -0
- data/sorbet/rbi/dsl/active_support/testing/file_fixtures.rbi +22 -0
- data/sorbet/rbi/gems/actionpack@7.0.4.3.rbi +19265 -0
- data/sorbet/rbi/gems/actionview@7.0.4.3.rbi +15482 -0
- data/sorbet/rbi/gems/activemodel@7.0.4.3.rbi +6025 -0
- data/sorbet/rbi/gems/activerecord@7.0.4.3.rbi +37852 -0
- data/sorbet/rbi/gems/activesupport@7.0.4.3.rbi +18788 -0
- data/sorbet/rbi/gems/addressable@2.4.0.rbi +8 -0
- data/sorbet/rbi/gems/appraisal@2.4.1.rbi +584 -0
- data/sorbet/rbi/gems/ast@2.4.2.rbi +584 -0
- data/sorbet/rbi/gems/builder@3.2.4.rbi +8 -0
- data/sorbet/rbi/gems/coderay@1.1.3.rbi +3426 -0
- data/sorbet/rbi/gems/commander@4.6.0.rbi +8 -0
- data/sorbet/rbi/gems/concurrent-ruby@1.2.2.rbi +11545 -0
- data/sorbet/rbi/gems/coveralls_reborn@0.27.0.rbi +8 -0
- data/sorbet/rbi/gems/crass@1.0.6.rbi +622 -0
- data/sorbet/rbi/gems/descendants_tracker@0.0.4.rbi +8 -0
- data/sorbet/rbi/gems/diff-lcs@1.5.0.rbi +1079 -0
- data/sorbet/rbi/gems/docile@1.4.0.rbi +8 -0
- data/sorbet/rbi/gems/erubi@1.12.0.rbi +146 -0
- data/sorbet/rbi/gems/faraday@0.9.2.rbi +964 -0
- data/sorbet/rbi/gems/git@1.11.0.rbi +2700 -0
- data/sorbet/rbi/gems/github_api@0.16.0.rbi +8 -0
- data/sorbet/rbi/gems/hashie@5.0.0.rbi +8 -0
- data/sorbet/rbi/gems/highline@2.0.3.rbi +8 -0
- data/sorbet/rbi/gems/i18n@1.12.0.rbi +2296 -0
- data/sorbet/rbi/gems/jeweler@2.3.9.rbi +1591 -0
- data/sorbet/rbi/gems/json@2.6.3.rbi +1541 -0
- data/sorbet/rbi/gems/jwt@2.5.0.rbi +8 -0
- data/sorbet/rbi/gems/loofah@2.19.1.rbi +904 -0
- data/sorbet/rbi/gems/method_source@1.0.0.rbi +272 -0
- data/sorbet/rbi/gems/mime-types@2.99.3.rbi +8 -0
- data/sorbet/rbi/gems/minitest@5.18.0.rbi +1491 -0
- data/sorbet/rbi/gems/multi_json@1.15.0.rbi +8 -0
- data/sorbet/rbi/gems/multi_xml@0.6.0.rbi +8 -0
- data/sorbet/rbi/gems/multipart-post@2.2.3.rbi +8 -0
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +158 -0
- data/sorbet/rbi/gems/nokogiri@1.14.2.rbi +7244 -0
- data/sorbet/rbi/gems/oauth2@1.4.8.rbi +8 -0
- data/sorbet/rbi/gems/parallel@1.22.1.rbi +277 -0
- data/sorbet/rbi/gems/pg@1.4.6.rbi +2574 -0
- data/sorbet/rbi/gems/polyfill@1.9.0.rbi +8 -0
- data/sorbet/rbi/gems/pry@0.14.2.rbi +10081 -0
- data/sorbet/rbi/gems/psych@4.0.6.rbi +1819 -0
- data/sorbet/rbi/gems/racc@1.6.2.rbi +155 -0
- data/sorbet/rbi/gems/rack-test@2.0.2.rbi +943 -0
- data/sorbet/rbi/gems/rack@2.2.6.4.rbi +5659 -0
- data/sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi +455 -0
- data/sorbet/rbi/gems/rails-html-sanitizer@1.5.0.rbi +685 -0
- data/sorbet/rbi/gems/railties@7.0.4.3.rbi +4553 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +8 -0
- data/sorbet/rbi/gems/rake@13.0.6.rbi +2959 -0
- data/sorbet/rbi/gems/rbi@0.0.16.rbi +3008 -0
- data/sorbet/rbi/gems/rbs@2.8.0.rbi +8 -0
- data/sorbet/rbi/gems/rchardet@1.8.0.rbi +1078 -0
- data/sorbet/rbi/gems/rdoc@6.5.0.rbi +12441 -0
- data/sorbet/rbi/gems/regexp_parser@2.7.0.rbi +8 -0
- data/sorbet/rbi/gems/rexml@3.2.5.rbi +8 -0
- data/sorbet/rbi/gems/rspec-core@3.12.0.rbi +10798 -0
- data/sorbet/rbi/gems/rspec-expectations@3.12.0.rbi +8090 -0
- data/sorbet/rbi/gems/rspec-mocks@3.12.0.rbi +5296 -0
- data/sorbet/rbi/gems/rspec-support@3.12.0.rbi +1617 -0
- data/sorbet/rbi/gems/rspec@3.12.0.rbi +88 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +8 -0
- data/sorbet/rbi/gems/safe_type@1.1.1.rbi +8 -0
- data/sorbet/rbi/gems/semver2@3.4.2.rbi +8 -0
- data/sorbet/rbi/gems/simplecov-html@0.12.3.rbi +8 -0
- data/sorbet/rbi/gems/simplecov@0.22.0.rbi +8 -0
- data/sorbet/rbi/gems/simplecov_json_formatter@0.1.4.rbi +8 -0
- data/sorbet/rbi/gems/sorbet-coerce@0.7.0.rbi +8 -0
- data/sorbet/rbi/gems/stringio@3.0.2.rbi +8 -0
- data/sorbet/rbi/gems/sync@0.5.0.rbi +8 -0
- data/sorbet/rbi/gems/term-ansicolor@1.7.1.rbi +8 -0
- data/sorbet/rbi/gems/thor@1.2.1.rbi +3956 -0
- data/sorbet/rbi/gems/thread_safe@0.3.6.rbi +8 -0
- data/sorbet/rbi/gems/timecop@0.9.6.rbi +361 -0
- data/sorbet/rbi/gems/tins@1.32.1.rbi +8 -0
- data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +5917 -0
- data/sorbet/rbi/gems/unicode-display_width@2.4.2.rbi +8 -0
- data/sorbet/rbi/gems/unparser@0.6.7.rbi +4515 -0
- data/sorbet/rbi/gems/webrick@1.7.0.rbi +2553 -0
- data/sorbet/rbi/gems/yard@0.9.28.rbi +17954 -0
- data/sorbet/rbi/gems/zeitwerk@2.6.7.rbi +966 -0
- data/sorbet/rbi/models/acts-as-messageable/message.rbi +668 -0
- data/sorbet/rbi/models/acts-as-messageable/user.rbi +343 -0
- data/sorbet/rbi/rails-rbi/active_record_base.rbi +119 -0
- data/sorbet/rbi/rails-rbi/active_record_relation.rbi +180 -0
- data/sorbet/rbi/shims/activerecord.rbi +4 -0
- data/sorbet/rbi/shims/model.rbi +9 -0
- data/sorbet/tapioca/config.yml +10 -0
- data/sorbet/tapioca/pre_require.rb +5 -0
- data/sorbet/tapioca/require.rb +10 -0
- data/spec/acts_as_messageable_spec.rb +7 -4
- data/spec/custom_class_spec.rb +1 -0
- data/spec/custom_required_spec.rb +8 -4
- data/spec/group_messages_spec.rb +1 -0
- data/spec/migrations_spec.rb +2 -1
- data/spec/spec_helper.rb +19 -9
- data/spec/support/admin.rb +3 -0
- data/spec/support/custom_message.rb +3 -0
- data/spec/support/custom_message_uuid.rb +1 -0
- data/spec/support/custom_search_user.rb +3 -0
- data/spec/support/men.rb +1 -0
- data/spec/support/send_message.rb +8 -1
- data/spec/support/table_schema.rb +7 -6
- data/spec/support/user.rb +3 -0
- data/spec/support/uuid_user.rb +3 -0
- data/tasks/types.rake +46 -0
- metadata +261 -11
- data/.travis.yml +0 -55
@@ -0,0 +1,964 @@
|
|
1
|
+
# typed: true
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `faraday` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem faraday`.
|
6
|
+
|
7
|
+
# Public: This is the main namespace for Faraday. You can either use it to
|
8
|
+
# create Faraday::Connection objects, or access it directly.
|
9
|
+
#
|
10
|
+
# Examples
|
11
|
+
#
|
12
|
+
# Faraday.get "http://faraday.com"
|
13
|
+
#
|
14
|
+
# conn = Faraday.new "http://faraday.com"
|
15
|
+
# conn.get '/'
|
16
|
+
#
|
17
|
+
# source://faraday//lib/faraday/connection.rb#1
|
18
|
+
module Faraday
|
19
|
+
class << self
|
20
|
+
# source://faraday//lib/faraday.rb#231
|
21
|
+
def const_missing(name); end
|
22
|
+
|
23
|
+
# Public: Gets or sets the Symbol key identifying a default Adapter to use
|
24
|
+
# for the default Faraday::Connection.
|
25
|
+
#
|
26
|
+
# source://faraday//lib/faraday.rb#29
|
27
|
+
def default_adapter; end
|
28
|
+
|
29
|
+
# Public: Updates default adapter while resetting
|
30
|
+
# #default_connection.
|
31
|
+
#
|
32
|
+
# Returns the new default_adapter.
|
33
|
+
#
|
34
|
+
# source://faraday//lib/faraday.rb#88
|
35
|
+
def default_adapter=(adapter); end
|
36
|
+
|
37
|
+
# Gets the default connection used for simple scripts.
|
38
|
+
#
|
39
|
+
# Returns a Faraday::Connection, configured with the #default_adapter.
|
40
|
+
#
|
41
|
+
# source://faraday//lib/faraday.rb#110
|
42
|
+
def default_connection; end
|
43
|
+
|
44
|
+
# Public: Sets the default Faraday::Connection for simple scripts that
|
45
|
+
# access the Faraday constant directly.
|
46
|
+
#
|
47
|
+
# Faraday.get "https://faraday.com"
|
48
|
+
#
|
49
|
+
# source://faraday//lib/faraday.rb#35
|
50
|
+
def default_connection=(_arg0); end
|
51
|
+
|
52
|
+
# Gets the default connection options used when calling Faraday#new.
|
53
|
+
#
|
54
|
+
# Returns a Faraday::ConnectionOptions.
|
55
|
+
#
|
56
|
+
# source://faraday//lib/faraday.rb#117
|
57
|
+
def default_connection_options; end
|
58
|
+
|
59
|
+
# Public: Sets the default options used when calling Faraday#new.
|
60
|
+
#
|
61
|
+
# source://faraday//lib/faraday.rb#38
|
62
|
+
def default_connection_options=(_arg0); end
|
63
|
+
|
64
|
+
# Public: Gets or sets the path that the Faraday libs are loaded from.
|
65
|
+
#
|
66
|
+
# source://faraday//lib/faraday.rb#25
|
67
|
+
def lib_path; end
|
68
|
+
|
69
|
+
# Public: Gets or sets the path that the Faraday libs are loaded from.
|
70
|
+
#
|
71
|
+
# source://faraday//lib/faraday.rb#25
|
72
|
+
def lib_path=(_arg0); end
|
73
|
+
|
74
|
+
# Public: Initializes a new Faraday::Connection.
|
75
|
+
#
|
76
|
+
# url - The optional String base URL to use as a prefix for all
|
77
|
+
# requests. Can also be the options Hash.
|
78
|
+
# options - The optional Hash used to configure this Faraday::Connection.
|
79
|
+
# Any of these values will be set on every request made, unless
|
80
|
+
# overridden for a specific request.
|
81
|
+
# :url - String base URL.
|
82
|
+
# :params - Hash of URI query unencoded key/value pairs.
|
83
|
+
# :headers - Hash of unencoded HTTP header key/value pairs.
|
84
|
+
# :request - Hash of request options.
|
85
|
+
# :ssl - Hash of SSL options.
|
86
|
+
# :proxy - Hash of Proxy options.
|
87
|
+
#
|
88
|
+
# Examples
|
89
|
+
#
|
90
|
+
# Faraday.new 'http://faraday.com'
|
91
|
+
#
|
92
|
+
# # http://faraday.com?page=1
|
93
|
+
# Faraday.new 'http://faraday.com', :params => {:page => 1}
|
94
|
+
#
|
95
|
+
# # same
|
96
|
+
#
|
97
|
+
# Faraday.new :url => 'http://faraday.com',
|
98
|
+
# :params => {:page => 1}
|
99
|
+
#
|
100
|
+
# Returns a Faraday::Connection.
|
101
|
+
#
|
102
|
+
# source://faraday//lib/faraday.rb#67
|
103
|
+
def new(url = T.unsafe(nil), options = T.unsafe(nil)); end
|
104
|
+
|
105
|
+
# Internal: Requires internal Faraday libraries.
|
106
|
+
#
|
107
|
+
# *libs - One or more relative String names to Faraday classes.
|
108
|
+
#
|
109
|
+
# Returns nothing.
|
110
|
+
#
|
111
|
+
# source://faraday//lib/faraday.rb#78
|
112
|
+
def require_lib(*libs); end
|
113
|
+
|
114
|
+
# Internal: Requires internal Faraday libraries.
|
115
|
+
#
|
116
|
+
# *libs - One or more relative String names to Faraday classes.
|
117
|
+
#
|
118
|
+
# Returns nothing.
|
119
|
+
#
|
120
|
+
# source://faraday//lib/faraday.rb#78
|
121
|
+
def require_libs(*libs); end
|
122
|
+
|
123
|
+
# Public: Gets or sets the root path that Faraday is being loaded from.
|
124
|
+
# This is the root from where the libraries are auto-loaded from.
|
125
|
+
#
|
126
|
+
# source://faraday//lib/faraday.rb#22
|
127
|
+
def root_path; end
|
128
|
+
|
129
|
+
# Public: Gets or sets the root path that Faraday is being loaded from.
|
130
|
+
# This is the root from where the libraries are auto-loaded from.
|
131
|
+
#
|
132
|
+
# source://faraday//lib/faraday.rb#22
|
133
|
+
def root_path=(_arg0); end
|
134
|
+
|
135
|
+
private
|
136
|
+
|
137
|
+
# Internal: Proxies method calls on the Faraday constant to
|
138
|
+
# #default_connection.
|
139
|
+
#
|
140
|
+
# source://faraday//lib/faraday.rb#98
|
141
|
+
def method_missing(name, *args, &block); end
|
142
|
+
end
|
143
|
+
end
|
144
|
+
|
145
|
+
# Public: Connection objects manage the default properties and the middleware
|
146
|
+
# stack for fulfilling an HTTP request.
|
147
|
+
#
|
148
|
+
# Examples
|
149
|
+
#
|
150
|
+
# conn = Faraday::Connection.new 'http://sushi.com'
|
151
|
+
#
|
152
|
+
# # GET http://sushi.com/nigiri
|
153
|
+
# conn.get 'nigiri'
|
154
|
+
# # => #<Faraday::Response>
|
155
|
+
#
|
156
|
+
# source://faraday//lib/faraday/connection.rb#13
|
157
|
+
class Faraday::Connection
|
158
|
+
extend ::Forwardable
|
159
|
+
|
160
|
+
# Public: Initializes a new Faraday::Connection.
|
161
|
+
#
|
162
|
+
# url - URI or String base URL to use as a prefix for all
|
163
|
+
# requests (optional).
|
164
|
+
# options - Hash or Faraday::ConnectionOptions.
|
165
|
+
# :url - URI or String base URL (default: "http:/").
|
166
|
+
# :params - Hash of URI query unencoded key/value pairs.
|
167
|
+
# :headers - Hash of unencoded HTTP header key/value pairs.
|
168
|
+
# :request - Hash of request options.
|
169
|
+
# :ssl - Hash of SSL options.
|
170
|
+
# :proxy - URI, String or Hash of HTTP proxy options
|
171
|
+
# (default: "http_proxy" environment variable).
|
172
|
+
# :uri - URI or String
|
173
|
+
# :user - String (optional)
|
174
|
+
# :password - String (optional)
|
175
|
+
#
|
176
|
+
# @return [Connection] a new instance of Connection
|
177
|
+
# @yield [_self]
|
178
|
+
# @yieldparam _self [Faraday::Connection] the object that the method was called on
|
179
|
+
#
|
180
|
+
# source://faraday//lib/faraday/connection.rb#57
|
181
|
+
def initialize(url = T.unsafe(nil), options = T.unsafe(nil)); end
|
182
|
+
|
183
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
184
|
+
def adapter(*args, **_arg1, &block); end
|
185
|
+
|
186
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
187
|
+
def app(*args, **_arg1, &block); end
|
188
|
+
|
189
|
+
# Public: Sets up a custom Authorization header.
|
190
|
+
#
|
191
|
+
# type - The String authorization type.
|
192
|
+
# token - The String or Hash token. A String value is taken literally, and
|
193
|
+
# a Hash is encoded into comma separated key/value pairs.
|
194
|
+
#
|
195
|
+
# Examples
|
196
|
+
#
|
197
|
+
# conn.authorization :Bearer, 'mF_9.B5f-4.1JqM'
|
198
|
+
# conn.headers['Authorization']
|
199
|
+
# # => "Bearer mF_9.B5f-4.1JqM"
|
200
|
+
#
|
201
|
+
# conn.authorization :Token, :token => 'abcdef', :foo => 'bar'
|
202
|
+
# conn.headers['Authorization']
|
203
|
+
# # => "Token token=\"abcdef\",
|
204
|
+
# foo=\"bar\""
|
205
|
+
#
|
206
|
+
# Returns nothing.
|
207
|
+
#
|
208
|
+
# source://faraday//lib/faraday/connection.rb#234
|
209
|
+
def authorization(type, token); end
|
210
|
+
|
211
|
+
# Public: Sets up the Authorization header with these credentials, encoded
|
212
|
+
# with base64.
|
213
|
+
#
|
214
|
+
# login - The authentication login.
|
215
|
+
# pass - The authentication password.
|
216
|
+
#
|
217
|
+
# Examples
|
218
|
+
#
|
219
|
+
# conn.basic_auth 'Aladdin', 'open sesame'
|
220
|
+
# conn.headers['Authorization']
|
221
|
+
# # => "Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ=="
|
222
|
+
#
|
223
|
+
# Returns nothing.
|
224
|
+
#
|
225
|
+
# source://faraday//lib/faraday/connection.rb#195
|
226
|
+
def basic_auth(login, pass); end
|
227
|
+
|
228
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
229
|
+
def build(*args, **_arg1, &block); end
|
230
|
+
|
231
|
+
# Internal: Build an absolute URL based on url_prefix.
|
232
|
+
#
|
233
|
+
# url - A String or URI-like object
|
234
|
+
# params - A Faraday::Utils::ParamsHash to replace the query values
|
235
|
+
# of the resulting url (default: nil).
|
236
|
+
#
|
237
|
+
# Returns the resulting URI instance.
|
238
|
+
#
|
239
|
+
# source://faraday//lib/faraday/connection.rb#399
|
240
|
+
def build_exclusive_url(url = T.unsafe(nil), params = T.unsafe(nil), params_encoder = T.unsafe(nil)); end
|
241
|
+
|
242
|
+
# Creates and configures the request object.
|
243
|
+
#
|
244
|
+
# Returns the new Request.
|
245
|
+
#
|
246
|
+
# source://faraday//lib/faraday/connection.rb#383
|
247
|
+
def build_request(method); end
|
248
|
+
|
249
|
+
# Public: Takes a relative url for a request and combines it with the defaults
|
250
|
+
# set on the connection instance.
|
251
|
+
#
|
252
|
+
# conn = Faraday::Connection.new { ... }
|
253
|
+
# conn.url_prefix = "https://sushi.com/api?token=abc"
|
254
|
+
# conn.scheme # => https
|
255
|
+
# conn.path_prefix # => "/api"
|
256
|
+
#
|
257
|
+
# conn.build_url("nigiri?page=2") # => https://sushi.com/api/nigiri?token=abc&page=2
|
258
|
+
# conn.build_url("nigiri", :page => 2) # => https://sushi.com/api/nigiri?token=abc&page=2
|
259
|
+
#
|
260
|
+
# source://faraday//lib/faraday/connection.rb#347
|
261
|
+
def build_url(url = T.unsafe(nil), extra_params = T.unsafe(nil)); end
|
262
|
+
|
263
|
+
# Public: Returns the Faraday::Builder for this Connection.
|
264
|
+
#
|
265
|
+
# source://faraday//lib/faraday/connection.rb#28
|
266
|
+
def builder; end
|
267
|
+
|
268
|
+
# Internal: Traverse the middleware stack in search of a
|
269
|
+
# parallel-capable adapter.
|
270
|
+
#
|
271
|
+
# Yields in case of not found.
|
272
|
+
#
|
273
|
+
# Returns a parallel manager or nil if not found.
|
274
|
+
#
|
275
|
+
# source://faraday//lib/faraday/connection.rb#244
|
276
|
+
def default_parallel_manager; end
|
277
|
+
|
278
|
+
# Public: Sets the default parallel manager for this connection.
|
279
|
+
#
|
280
|
+
# source://faraday//lib/faraday/connection.rb#40
|
281
|
+
def default_parallel_manager=(_arg0); end
|
282
|
+
|
283
|
+
# source://faraday//lib/faraday/connection.rb#139
|
284
|
+
def delete(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
285
|
+
|
286
|
+
# Internal: Creates a duplicate of this Faraday::Connection.
|
287
|
+
#
|
288
|
+
# Returns a Faraday::Connection.
|
289
|
+
#
|
290
|
+
# source://faraday//lib/faraday/connection.rb#415
|
291
|
+
def dup; end
|
292
|
+
|
293
|
+
# source://faraday//lib/faraday/connection.rb#139
|
294
|
+
def get(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
295
|
+
|
296
|
+
# source://faraday//lib/faraday/connection.rb#139
|
297
|
+
def head(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
298
|
+
|
299
|
+
# Public: Returns a Hash of unencoded HTTP header key/value pairs.
|
300
|
+
#
|
301
|
+
# source://faraday//lib/faraday/connection.rb#21
|
302
|
+
def headers; end
|
303
|
+
|
304
|
+
# Public: Sets the Hash of unencoded HTTP header key/value pairs.
|
305
|
+
#
|
306
|
+
# source://faraday//lib/faraday/connection.rb#102
|
307
|
+
def headers=(hash); end
|
308
|
+
|
309
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
310
|
+
def host(*args, **_arg1, &block); end
|
311
|
+
|
312
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
313
|
+
def host=(*args, **_arg1, &block); end
|
314
|
+
|
315
|
+
# Public: Sets up the parallel manager to make a set of requests.
|
316
|
+
#
|
317
|
+
# manager - The parallel manager that this Connection's Adapter uses.
|
318
|
+
#
|
319
|
+
# Yields a block to execute multiple requests.
|
320
|
+
# Returns nothing.
|
321
|
+
#
|
322
|
+
# source://faraday//lib/faraday/connection.rb#271
|
323
|
+
def in_parallel(manager = T.unsafe(nil)); end
|
324
|
+
|
325
|
+
# Public: Determine if this Faraday::Connection can make parallel requests.
|
326
|
+
#
|
327
|
+
# Returns true or false.
|
328
|
+
#
|
329
|
+
# @return [Boolean]
|
330
|
+
#
|
331
|
+
# source://faraday//lib/faraday/connection.rb#261
|
332
|
+
def in_parallel?; end
|
333
|
+
|
334
|
+
# Public: Returns a Hash of the request options.
|
335
|
+
#
|
336
|
+
# source://faraday//lib/faraday/connection.rb#31
|
337
|
+
def options; end
|
338
|
+
|
339
|
+
# Public: Returns the parallel manager for this Connection.
|
340
|
+
#
|
341
|
+
# source://faraday//lib/faraday/connection.rb#37
|
342
|
+
def parallel_manager; end
|
343
|
+
|
344
|
+
# Public: Returns a Hash of URI query unencoded key/value pairs.
|
345
|
+
#
|
346
|
+
# source://faraday//lib/faraday/connection.rb#18
|
347
|
+
def params; end
|
348
|
+
|
349
|
+
# Public: Sets the Hash of URI query unencoded key/value pairs.
|
350
|
+
#
|
351
|
+
# source://faraday//lib/faraday/connection.rb#97
|
352
|
+
def params=(hash); end
|
353
|
+
|
354
|
+
# source://faraday//lib/faraday/connection.rb#176
|
355
|
+
def patch(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
356
|
+
|
357
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
358
|
+
def path_prefix(*args, **_arg1, &block); end
|
359
|
+
|
360
|
+
# Public: Sets the path prefix and ensures that it always has a leading
|
361
|
+
# slash.
|
362
|
+
#
|
363
|
+
# value - A String.
|
364
|
+
#
|
365
|
+
# Returns the new String path prefix.
|
366
|
+
#
|
367
|
+
# source://faraday//lib/faraday/connection.rb#329
|
368
|
+
def path_prefix=(value); end
|
369
|
+
|
370
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
371
|
+
def port(*args, **_arg1, &block); end
|
372
|
+
|
373
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
374
|
+
def port=(*args, **_arg1, &block); end
|
375
|
+
|
376
|
+
# source://faraday//lib/faraday/connection.rb#176
|
377
|
+
def post(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
378
|
+
|
379
|
+
# Public: Gets or Sets the Hash proxy options.
|
380
|
+
#
|
381
|
+
# source://faraday//lib/faraday/connection.rb#284
|
382
|
+
def proxy(arg = T.unsafe(nil)); end
|
383
|
+
|
384
|
+
# source://faraday//lib/faraday/connection.rb#176
|
385
|
+
def put(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
386
|
+
|
387
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
388
|
+
def request(*args, **_arg1, &block); end
|
389
|
+
|
390
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
391
|
+
def response(*args, **_arg1, &block); end
|
392
|
+
|
393
|
+
# Builds and runs the Faraday::Request.
|
394
|
+
#
|
395
|
+
# method - The Symbol HTTP method.
|
396
|
+
# url - The String or URI to access.
|
397
|
+
# body - The String body
|
398
|
+
# headers - Hash of unencoded HTTP header key/value pairs.
|
399
|
+
#
|
400
|
+
# Returns a Faraday::Response.
|
401
|
+
#
|
402
|
+
# source://faraday//lib/faraday/connection.rb#365
|
403
|
+
def run_request(method, url, body, headers); end
|
404
|
+
|
405
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
406
|
+
def scheme(*args, **_arg1, &block); end
|
407
|
+
|
408
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
409
|
+
def scheme=(*args, **_arg1, &block); end
|
410
|
+
|
411
|
+
# source://faraday//lib/faraday/connection.rb#431
|
412
|
+
def set_authorization_header(header_type, *args); end
|
413
|
+
|
414
|
+
# Public: Returns a Hash of the SSL options.
|
415
|
+
#
|
416
|
+
# source://faraday//lib/faraday/connection.rb#34
|
417
|
+
def ssl; end
|
418
|
+
|
419
|
+
# Public: Sets up the Authorization header with the given token.
|
420
|
+
#
|
421
|
+
# token - The String token.
|
422
|
+
# options - Optional Hash of extra token options.
|
423
|
+
#
|
424
|
+
# Examples
|
425
|
+
#
|
426
|
+
# conn.token_auth 'abcdef', :foo => 'bar'
|
427
|
+
# conn.headers['Authorization']
|
428
|
+
# # => "Token token=\"abcdef\",
|
429
|
+
# foo=\"bar\""
|
430
|
+
#
|
431
|
+
# Returns nothing.
|
432
|
+
#
|
433
|
+
# source://faraday//lib/faraday/connection.rb#212
|
434
|
+
def token_auth(token, options = T.unsafe(nil)); end
|
435
|
+
|
436
|
+
# Public: Returns a URI with the prefix used for all requests from this
|
437
|
+
# Connection. This includes a default host name, scheme, port, and path.
|
438
|
+
#
|
439
|
+
# source://faraday//lib/faraday/connection.rb#25
|
440
|
+
def url_prefix; end
|
441
|
+
|
442
|
+
# Public: Parses the giving url with URI and stores the individual
|
443
|
+
# components in this connection. These components serve as defaults for
|
444
|
+
# requests made by this connection.
|
445
|
+
#
|
446
|
+
# url - A String or URI.
|
447
|
+
#
|
448
|
+
# Examples
|
449
|
+
#
|
450
|
+
# conn = Faraday::Connection.new { ... }
|
451
|
+
# conn.url_prefix = "https://sushi.com/api"
|
452
|
+
# conn.scheme # => https
|
453
|
+
# conn.path_prefix # => "/api"
|
454
|
+
#
|
455
|
+
# conn.get("nigiri?page=2") # accesses https://sushi.com/api/nigiri
|
456
|
+
#
|
457
|
+
# Returns the parsed URI from teh given input..
|
458
|
+
#
|
459
|
+
# source://faraday//lib/faraday/connection.rb#308
|
460
|
+
def url_prefix=(url, encoder = T.unsafe(nil)); end
|
461
|
+
|
462
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
463
|
+
def use(*args, **_arg1, &block); end
|
464
|
+
|
465
|
+
# Internal: Yields username and password extracted from a URI if they both exist.
|
466
|
+
#
|
467
|
+
# source://faraday//lib/faraday/connection.rb#425
|
468
|
+
def with_uri_credentials(uri); end
|
469
|
+
end
|
470
|
+
|
471
|
+
# A Set of allowed HTTP verbs.
|
472
|
+
#
|
473
|
+
# source://faraday//lib/faraday/connection.rb#15
|
474
|
+
Faraday::Connection::METHODS = T.let(T.unsafe(nil), Set)
|
475
|
+
|
476
|
+
# Public: Adds the ability for other modules to register and lookup
|
477
|
+
# middleware classes.
|
478
|
+
#
|
479
|
+
# source://faraday//lib/faraday.rb#137
|
480
|
+
module Faraday::MiddlewareRegistry
|
481
|
+
# source://faraday//lib/faraday.rb#200
|
482
|
+
def fetch_middleware(key); end
|
483
|
+
|
484
|
+
# source://faraday//lib/faraday.rb#204
|
485
|
+
def load_middleware(key); end
|
486
|
+
|
487
|
+
# Public: Lookup middleware class with a registered Symbol shortcut.
|
488
|
+
#
|
489
|
+
# key - The Symbol key for the registered middleware.
|
490
|
+
#
|
491
|
+
# Examples
|
492
|
+
#
|
493
|
+
# module Faraday
|
494
|
+
# class Whatever
|
495
|
+
# register_middleware :foo => Foo
|
496
|
+
# end
|
497
|
+
# end
|
498
|
+
#
|
499
|
+
# Faraday::Whatever.lookup_middleware(:foo)
|
500
|
+
# # => Faraday::Whatever::Foo
|
501
|
+
#
|
502
|
+
# Returns a middleware Class.
|
503
|
+
#
|
504
|
+
# source://faraday//lib/faraday.rb#187
|
505
|
+
def lookup_middleware(key); end
|
506
|
+
|
507
|
+
# source://faraday//lib/faraday.rb#192
|
508
|
+
def middleware_mutex(&block); end
|
509
|
+
|
510
|
+
# Public: Register middleware class(es) on the current module.
|
511
|
+
#
|
512
|
+
# mapping - A Hash mapping Symbol keys to classes. Classes can be expressed
|
513
|
+
# as fully qualified constant, or a Proc that will be lazily
|
514
|
+
# called to return the former.
|
515
|
+
#
|
516
|
+
# Examples
|
517
|
+
#
|
518
|
+
# module Faraday
|
519
|
+
# class Whatever
|
520
|
+
# # Middleware looked up by :foo returns Faraday::Whatever::Foo.
|
521
|
+
# register_middleware :foo => Foo
|
522
|
+
#
|
523
|
+
# # Middleware looked up by :bar returns Faraday::Whatever.const_get(:Bar)
|
524
|
+
# register_middleware :bar => :Bar
|
525
|
+
#
|
526
|
+
# # Middleware looked up by :baz requires 'baz' and returns Faraday::Whatever.const_get(:Baz)
|
527
|
+
# register_middleware :baz => [:Baz, 'baz']
|
528
|
+
# end
|
529
|
+
# end
|
530
|
+
#
|
531
|
+
# Returns nothing.
|
532
|
+
#
|
533
|
+
# source://faraday//lib/faraday.rb#160
|
534
|
+
def register_middleware(autoload_path = T.unsafe(nil), mapping = T.unsafe(nil)); end
|
535
|
+
end
|
536
|
+
|
537
|
+
# Subclasses Struct with some special helpers for converting from a Hash to
|
538
|
+
# a Struct.
|
539
|
+
#
|
540
|
+
# source://faraday//lib/faraday/options.rb#5
|
541
|
+
class Faraday::Options < ::Struct
|
542
|
+
# source://faraday//lib/faraday/options.rb#163
|
543
|
+
def [](key); end
|
544
|
+
|
545
|
+
# Public
|
546
|
+
#
|
547
|
+
# source://faraday//lib/faraday/options.rb#46
|
548
|
+
def clear; end
|
549
|
+
|
550
|
+
# Public
|
551
|
+
#
|
552
|
+
# source://faraday//lib/faraday/options.rb#39
|
553
|
+
def delete(key); end
|
554
|
+
|
555
|
+
# Public
|
556
|
+
#
|
557
|
+
# source://faraday//lib/faraday/options.rb#11
|
558
|
+
def each; end
|
559
|
+
|
560
|
+
# Public
|
561
|
+
#
|
562
|
+
# source://faraday//lib/faraday/options.rb#86
|
563
|
+
def each_key; end
|
564
|
+
|
565
|
+
# Public
|
566
|
+
#
|
567
|
+
# source://faraday//lib/faraday/options.rb#101
|
568
|
+
def each_value; end
|
569
|
+
|
570
|
+
# Public
|
571
|
+
#
|
572
|
+
# @return [Boolean]
|
573
|
+
#
|
574
|
+
# source://faraday//lib/faraday/options.rb#81
|
575
|
+
def empty?; end
|
576
|
+
|
577
|
+
# Public
|
578
|
+
#
|
579
|
+
# source://faraday//lib/faraday/options.rb#56
|
580
|
+
def fetch(key, *args); end
|
581
|
+
|
582
|
+
# Public
|
583
|
+
#
|
584
|
+
# @return [Boolean]
|
585
|
+
#
|
586
|
+
# source://faraday//lib/faraday/options.rb#94
|
587
|
+
def has_key?(key); end
|
588
|
+
|
589
|
+
# Public
|
590
|
+
#
|
591
|
+
# @return [Boolean]
|
592
|
+
#
|
593
|
+
# source://faraday//lib/faraday/options.rb#109
|
594
|
+
def has_value?(value); end
|
595
|
+
|
596
|
+
# Internal
|
597
|
+
#
|
598
|
+
# source://faraday//lib/faraday/options.rb#126
|
599
|
+
def inspect; end
|
600
|
+
|
601
|
+
# Public
|
602
|
+
#
|
603
|
+
# @return [Boolean]
|
604
|
+
#
|
605
|
+
# source://faraday//lib/faraday/options.rb#94
|
606
|
+
def key?(key); end
|
607
|
+
|
608
|
+
# Public
|
609
|
+
#
|
610
|
+
# source://faraday//lib/faraday/options.rb#76
|
611
|
+
def keys; end
|
612
|
+
|
613
|
+
# Public
|
614
|
+
#
|
615
|
+
# source://faraday//lib/faraday/options.rb#51
|
616
|
+
def merge(value); end
|
617
|
+
|
618
|
+
# Public
|
619
|
+
#
|
620
|
+
# source://faraday//lib/faraday/options.rb#19
|
621
|
+
def merge!(obj); end
|
622
|
+
|
623
|
+
# source://faraday//lib/faraday/options.rb#172
|
624
|
+
def symbolized_key_set; end
|
625
|
+
|
626
|
+
# Public
|
627
|
+
#
|
628
|
+
# source://faraday//lib/faraday/options.rb#116
|
629
|
+
def to_hash; end
|
630
|
+
|
631
|
+
# Public
|
632
|
+
#
|
633
|
+
# source://faraday//lib/faraday/options.rb#19
|
634
|
+
def update(obj); end
|
635
|
+
|
636
|
+
# Public
|
637
|
+
#
|
638
|
+
# @return [Boolean]
|
639
|
+
#
|
640
|
+
# source://faraday//lib/faraday/options.rb#109
|
641
|
+
def value?(value); end
|
642
|
+
|
643
|
+
# Public
|
644
|
+
#
|
645
|
+
# source://faraday//lib/faraday/options.rb#71
|
646
|
+
def values_at(*keys); end
|
647
|
+
|
648
|
+
class << self
|
649
|
+
# Internal
|
650
|
+
#
|
651
|
+
# source://faraday//lib/faraday/options.rb#148
|
652
|
+
def attribute_options; end
|
653
|
+
|
654
|
+
# source://faraday//lib/faraday/options.rb#182
|
655
|
+
def fetch_error_class; end
|
656
|
+
|
657
|
+
# Public
|
658
|
+
#
|
659
|
+
# source://faraday//lib/faraday/options.rb#6
|
660
|
+
def from(value); end
|
661
|
+
|
662
|
+
# @private
|
663
|
+
#
|
664
|
+
# source://faraday//lib/faraday/options.rb#176
|
665
|
+
def inherited(subclass); end
|
666
|
+
|
667
|
+
# source://faraday//lib/faraday/options.rb#152
|
668
|
+
def memoized(key); end
|
669
|
+
|
670
|
+
# source://faraday//lib/faraday/options.rb#159
|
671
|
+
def memoized_attributes; end
|
672
|
+
|
673
|
+
# Internal
|
674
|
+
#
|
675
|
+
# source://faraday//lib/faraday/options.rb#138
|
676
|
+
def options(mapping); end
|
677
|
+
|
678
|
+
# Internal
|
679
|
+
#
|
680
|
+
# source://faraday//lib/faraday/options.rb#143
|
681
|
+
def options_for(key); end
|
682
|
+
end
|
683
|
+
end
|
684
|
+
|
685
|
+
# source://faraday//lib/faraday/options.rb#216
|
686
|
+
class Faraday::ProxyOptions < ::Faraday::Options
|
687
|
+
extend ::Forwardable
|
688
|
+
|
689
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
690
|
+
def host(*args, **_arg1, &block); end
|
691
|
+
|
692
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
693
|
+
def host=(*args, **_arg1, &block); end
|
694
|
+
|
695
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
696
|
+
def path(*args, **_arg1, &block); end
|
697
|
+
|
698
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
699
|
+
def path=(*args, **_arg1, &block); end
|
700
|
+
|
701
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
702
|
+
def port(*args, **_arg1, &block); end
|
703
|
+
|
704
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
705
|
+
def port=(*args, **_arg1, &block); end
|
706
|
+
|
707
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
708
|
+
def scheme(*args, **_arg1, &block); end
|
709
|
+
|
710
|
+
# source://forwardable/1.3.2/forwardable.rb#229
|
711
|
+
def scheme=(*args, **_arg1, &block); end
|
712
|
+
|
713
|
+
class << self
|
714
|
+
# source://faraday//lib/faraday/options.rb#220
|
715
|
+
def from(value); end
|
716
|
+
end
|
717
|
+
end
|
718
|
+
|
719
|
+
# source://faraday//lib/faraday/options.rb#193
|
720
|
+
class Faraday::RequestOptions < ::Faraday::Options
|
721
|
+
# source://faraday//lib/faraday/options.rb#195
|
722
|
+
def []=(key, value); end
|
723
|
+
end
|
724
|
+
|
725
|
+
# source://faraday//lib/faraday/options.rb#205
|
726
|
+
class Faraday::SSLOptions < ::Faraday::Options
|
727
|
+
# @return [Boolean]
|
728
|
+
#
|
729
|
+
# source://faraday//lib/faraday/options.rb#211
|
730
|
+
def disable?; end
|
731
|
+
|
732
|
+
# @return [Boolean]
|
733
|
+
#
|
734
|
+
# source://faraday//lib/faraday/options.rb#207
|
735
|
+
def verify?; end
|
736
|
+
end
|
737
|
+
|
738
|
+
# source://faraday//lib/faraday.rb#132
|
739
|
+
Faraday::Timer = Timeout
|
740
|
+
|
741
|
+
# source://faraday//lib/faraday/utils.rb#4
|
742
|
+
module Faraday::Utils
|
743
|
+
extend ::Faraday::Utils
|
744
|
+
|
745
|
+
# Normalize URI() behavior across Ruby versions
|
746
|
+
#
|
747
|
+
# url - A String or URI.
|
748
|
+
#
|
749
|
+
# Returns a parsed URI.
|
750
|
+
#
|
751
|
+
# source://faraday//lib/faraday/utils.rb#254
|
752
|
+
def URI(url); end
|
753
|
+
|
754
|
+
# source://faraday//lib/faraday/utils.rb#179
|
755
|
+
def build_nested_query(params); end
|
756
|
+
|
757
|
+
# source://faraday//lib/faraday/utils.rb#175
|
758
|
+
def build_query(params); end
|
759
|
+
|
760
|
+
# Recursive hash merge
|
761
|
+
#
|
762
|
+
# source://faraday//lib/faraday/utils.rb#299
|
763
|
+
def deep_merge(source, hash); end
|
764
|
+
|
765
|
+
# Recursive hash update
|
766
|
+
#
|
767
|
+
# source://faraday//lib/faraday/utils.rb#287
|
768
|
+
def deep_merge!(target, hash); end
|
769
|
+
|
770
|
+
# source://faraday//lib/faraday/utils.rb#204
|
771
|
+
def default_params_encoder; end
|
772
|
+
|
773
|
+
# source://faraday//lib/faraday/utils.rb#264
|
774
|
+
def default_uri_parser; end
|
775
|
+
|
776
|
+
# source://faraday//lib/faraday/utils.rb#271
|
777
|
+
def default_uri_parser=(parser); end
|
778
|
+
|
779
|
+
# source://faraday//lib/faraday/utils.rb#185
|
780
|
+
def escape(s); end
|
781
|
+
|
782
|
+
# Stolen from Rack
|
783
|
+
#
|
784
|
+
# source://faraday//lib/faraday/utils.rb#213
|
785
|
+
def normalize_params(params, name, v = T.unsafe(nil)); end
|
786
|
+
|
787
|
+
# Receives a String or URI and returns just the path with the query string sorted.
|
788
|
+
#
|
789
|
+
# source://faraday//lib/faraday/utils.rb#280
|
790
|
+
def normalize_path(url); end
|
791
|
+
|
792
|
+
# source://faraday//lib/faraday/utils.rb#200
|
793
|
+
def parse_nested_query(query); end
|
794
|
+
|
795
|
+
# Adapted from Rack
|
796
|
+
#
|
797
|
+
# source://faraday//lib/faraday/utils.rb#196
|
798
|
+
def parse_query(query); end
|
799
|
+
|
800
|
+
# source://faraday//lib/faraday/utils.rb#191
|
801
|
+
def unescape(s); end
|
802
|
+
|
803
|
+
protected
|
804
|
+
|
805
|
+
# source://faraday//lib/faraday/utils.rb#305
|
806
|
+
def sort_query_params(query); end
|
807
|
+
|
808
|
+
class << self
|
809
|
+
# Sets the attribute default_params_encoder
|
810
|
+
#
|
811
|
+
# @param value the value to set the attribute default_params_encoder to.
|
812
|
+
#
|
813
|
+
# source://faraday//lib/faraday/utils.rb#209
|
814
|
+
def default_params_encoder=(_arg0); end
|
815
|
+
end
|
816
|
+
end
|
817
|
+
|
818
|
+
# source://faraday//lib/faraday/utils.rb#193
|
819
|
+
Faraday::Utils::DEFAULT_SEP = T.let(T.unsafe(nil), Regexp)
|
820
|
+
|
821
|
+
# source://faraday//lib/faraday/utils.rb#183
|
822
|
+
Faraday::Utils::ESCAPE_RE = T.let(T.unsafe(nil), Regexp)
|
823
|
+
|
824
|
+
# Adapted from Rack::Utils::HeaderHash
|
825
|
+
#
|
826
|
+
# source://faraday//lib/faraday/utils.rb#8
|
827
|
+
class Faraday::Utils::Headers < ::Hash
|
828
|
+
# @return [Headers] a new instance of Headers
|
829
|
+
#
|
830
|
+
# source://faraday//lib/faraday/utils.rb#13
|
831
|
+
def initialize(hash = T.unsafe(nil)); end
|
832
|
+
|
833
|
+
# source://faraday//lib/faraday/utils.rb#41
|
834
|
+
def [](k); end
|
835
|
+
|
836
|
+
# source://faraday//lib/faraday/utils.rb#46
|
837
|
+
def []=(k, v); end
|
838
|
+
|
839
|
+
# source://faraday//lib/faraday/utils.rb#60
|
840
|
+
def delete(k); end
|
841
|
+
|
842
|
+
# source://faraday//lib/faraday/utils.rb#54
|
843
|
+
def fetch(k, *args, &block); end
|
844
|
+
|
845
|
+
# @return [Boolean]
|
846
|
+
#
|
847
|
+
# source://faraday//lib/faraday/utils.rb#68
|
848
|
+
def has_key?(k); end
|
849
|
+
|
850
|
+
# @return [Boolean]
|
851
|
+
#
|
852
|
+
# source://faraday//lib/faraday/utils.rb#68
|
853
|
+
def include?(k); end
|
854
|
+
|
855
|
+
# @return [Boolean]
|
856
|
+
#
|
857
|
+
# source://faraday//lib/faraday/utils.rb#68
|
858
|
+
def key?(k); end
|
859
|
+
|
860
|
+
# @return [Boolean]
|
861
|
+
#
|
862
|
+
# source://faraday//lib/faraday/utils.rb#68
|
863
|
+
def member?(k); end
|
864
|
+
|
865
|
+
# source://faraday//lib/faraday/utils.rb#82
|
866
|
+
def merge(other); end
|
867
|
+
|
868
|
+
# source://faraday//lib/faraday/utils.rb#76
|
869
|
+
def merge!(other); end
|
870
|
+
|
871
|
+
# source://faraday//lib/faraday/utils.rb#96
|
872
|
+
def parse(header_string); end
|
873
|
+
|
874
|
+
# source://faraday//lib/faraday/utils.rb#87
|
875
|
+
def replace(other); end
|
876
|
+
|
877
|
+
# source://faraday//lib/faraday/utils.rb#94
|
878
|
+
def to_hash; end
|
879
|
+
|
880
|
+
# source://faraday//lib/faraday/utils.rb#76
|
881
|
+
def update(other); end
|
882
|
+
|
883
|
+
protected
|
884
|
+
|
885
|
+
# source://faraday//lib/faraday/utils.rb#113
|
886
|
+
def names; end
|
887
|
+
|
888
|
+
private
|
889
|
+
|
890
|
+
# on dup/clone, we need to duplicate @names hash
|
891
|
+
#
|
892
|
+
# source://faraday//lib/faraday/utils.rb#20
|
893
|
+
def initialize_copy(other); end
|
894
|
+
|
895
|
+
class << self
|
896
|
+
# source://faraday//lib/faraday/utils.rb#9
|
897
|
+
def from(value); end
|
898
|
+
end
|
899
|
+
end
|
900
|
+
|
901
|
+
# symbol -> string mapper + cache
|
902
|
+
#
|
903
|
+
# source://faraday//lib/faraday/utils.rb#29
|
904
|
+
Faraday::Utils::Headers::KeyMap = T.let(T.unsafe(nil), Hash)
|
905
|
+
|
906
|
+
# hash with stringified keys
|
907
|
+
#
|
908
|
+
# source://faraday//lib/faraday/utils.rb#119
|
909
|
+
class Faraday::Utils::ParamsHash < ::Hash
|
910
|
+
# source://faraday//lib/faraday/utils.rb#120
|
911
|
+
def [](key); end
|
912
|
+
|
913
|
+
# source://faraday//lib/faraday/utils.rb#124
|
914
|
+
def []=(key, value); end
|
915
|
+
|
916
|
+
# source://faraday//lib/faraday/utils.rb#128
|
917
|
+
def delete(key); end
|
918
|
+
|
919
|
+
# @return [Boolean]
|
920
|
+
#
|
921
|
+
# source://faraday//lib/faraday/utils.rb#132
|
922
|
+
def has_key?(key); end
|
923
|
+
|
924
|
+
# @return [Boolean]
|
925
|
+
#
|
926
|
+
# source://faraday//lib/faraday/utils.rb#132
|
927
|
+
def include?(key); end
|
928
|
+
|
929
|
+
# @return [Boolean]
|
930
|
+
#
|
931
|
+
# source://faraday//lib/faraday/utils.rb#132
|
932
|
+
def key?(key); end
|
933
|
+
|
934
|
+
# @return [Boolean]
|
935
|
+
#
|
936
|
+
# source://faraday//lib/faraday/utils.rb#132
|
937
|
+
def member?(key); end
|
938
|
+
|
939
|
+
# source://faraday//lib/faraday/utils.rb#148
|
940
|
+
def merge(params); end
|
941
|
+
|
942
|
+
# source://faraday//lib/faraday/utils.rb#140
|
943
|
+
def merge!(params); end
|
944
|
+
|
945
|
+
# source://faraday//lib/faraday/utils.rb#157
|
946
|
+
def merge_query(query, encoder = T.unsafe(nil)); end
|
947
|
+
|
948
|
+
# source://faraday//lib/faraday/utils.rb#152
|
949
|
+
def replace(other); end
|
950
|
+
|
951
|
+
# source://faraday//lib/faraday/utils.rb#164
|
952
|
+
def to_query(encoder = T.unsafe(nil)); end
|
953
|
+
|
954
|
+
# source://faraday//lib/faraday/utils.rb#140
|
955
|
+
def update(params); end
|
956
|
+
|
957
|
+
private
|
958
|
+
|
959
|
+
# source://faraday//lib/faraday/utils.rb#170
|
960
|
+
def convert_key(key); end
|
961
|
+
end
|
962
|
+
|
963
|
+
# source://faraday//lib/faraday.rb#17
|
964
|
+
Faraday::VERSION = T.let(T.unsafe(nil), String)
|