checkoff 0.223.0 → 0.225.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (227) hide show
  1. checksums.yaml +4 -4
  2. data/checkoff.gemspec +10 -5
  3. data/lib/checkoff/cli.rb +1 -1
  4. data/lib/checkoff/clients.rb +1 -1
  5. data/lib/checkoff/custom_fields.rb +1 -1
  6. data/lib/checkoff/events.rb +1 -1
  7. data/lib/checkoff/internal/config_loader.rb +2 -3
  8. data/lib/checkoff/internal/selector_classes/section/function_evaluator.rb +3 -2
  9. data/lib/checkoff/my_tasks.rb +1 -1
  10. data/lib/checkoff/portfolios.rb +11 -9
  11. data/lib/checkoff/projects.rb +1 -1
  12. data/lib/checkoff/sections.rb +3 -4
  13. data/lib/checkoff/tags.rb +66 -17
  14. data/lib/checkoff/tasks.rb +1 -1
  15. data/lib/checkoff/version.rb +1 -1
  16. data/lib/checkoff/workspaces.rb +1 -1
  17. data/rbi/checkoff.rbi +4529 -0
  18. data/sig/checkoff.rbs +3749 -0
  19. metadata +4 -210
  20. data/.circleci/config.yml +0 -291
  21. data/.envrc +0 -9
  22. data/.git-hooks/pre_commit/circle_ci.rb +0 -26
  23. data/.git-hooks/pre_commit/punchlist.rb +0 -52
  24. data/.git-hooks/pre_commit/solargraph_typecheck.rb +0 -77
  25. data/.gitattributes +0 -6
  26. data/.gitignore +0 -65
  27. data/.markdownlint_style.rb +0 -4
  28. data/.mdlrc +0 -1
  29. data/.overcommit.yml +0 -115
  30. data/.rubocop.yml +0 -143
  31. data/.rubocop_todo.yml +0 -90
  32. data/.solargraph.yml +0 -35
  33. data/.yamllint.yml +0 -8
  34. data/.yardopts +0 -2
  35. data/CODE_OF_CONDUCT.md +0 -133
  36. data/CONTRIBUTING.rst +0 -75
  37. data/DEVELOPMENT.md +0 -69
  38. data/GLOSSARY.md +0 -16
  39. data/Gemfile +0 -67
  40. data/Gemfile.lock +0 -351
  41. data/LICENSE +0 -21
  42. data/Makefile +0 -139
  43. data/bin/brakeman +0 -27
  44. data/bin/bump +0 -29
  45. data/bin/checkoff +0 -29
  46. data/bin/console +0 -15
  47. data/bin/overcommit +0 -29
  48. data/bin/overcommit_branch +0 -114
  49. data/bin/rake +0 -29
  50. data/bin/rubocop +0 -27
  51. data/bin/setup +0 -8
  52. data/bin/solargraph +0 -27
  53. data/bin/sord +0 -27
  54. data/bin/spoom +0 -27
  55. data/bin/srb +0 -27
  56. data/bin/srb-rbi +0 -27
  57. data/bin/tapioca +0 -27
  58. data/bin/yard +0 -27
  59. data/config/annotations_asana.rb +0 -253
  60. data/config/annotations_misc.rb +0 -68
  61. data/config/env.1p +0 -2
  62. data/docs/.gitignore +0 -3
  63. data/docs/cookiecutter_input.json +0 -17
  64. data/docs/example_project.png +0 -0
  65. data/fix.sh +0 -534
  66. data/metrics/bigfiles_high_water_mark +0 -1
  67. data/metrics/brakeman_high_water_mark +0 -1
  68. data/metrics/bundle-audit_high_water_mark +0 -1
  69. data/metrics/cane_high_water_mark +0 -1
  70. data/metrics/eslint_high_water_mark +0 -1
  71. data/metrics/flake8_high_water_mark +0 -1
  72. data/metrics/flay_high_water_mark +0 -1
  73. data/metrics/flog_high_water_mark +0 -1
  74. data/metrics/jscs_high_water_mark +0 -1
  75. data/metrics/mdl_high_water_mark +0 -1
  76. data/metrics/pep8_high_water_mark +0 -1
  77. data/metrics/punchlist_high_water_mark +0 -1
  78. data/metrics/pycodestyle_high_water_mark +0 -1
  79. data/metrics/rails_best_practices_high_water_mark +0 -1
  80. data/metrics/rubocop_high_water_mark +0 -1
  81. data/metrics/scalastyle_high_water_mark +0 -1
  82. data/metrics/shellcheck_high_water_mark +0 -1
  83. data/package.json +0 -9
  84. data/rakelib/citest.rake +0 -4
  85. data/rakelib/clear_metrics.rake +0 -9
  86. data/rakelib/console.rake +0 -15
  87. data/rakelib/default.rake +0 -4
  88. data/rakelib/doc.rake +0 -6
  89. data/rakelib/gem_tasks.rake +0 -3
  90. data/rakelib/localtest.rake +0 -4
  91. data/rakelib/overcommit.rake +0 -6
  92. data/rakelib/quality.rake +0 -4
  93. data/rakelib/repl.rake +0 -4
  94. data/rakelib/test.rake +0 -10
  95. data/rakelib/trigger_next_builds.rake +0 -7
  96. data/rakelib/undercover.rake +0 -8
  97. data/requirements_dev.txt +0 -2
  98. data/sorbet/config +0 -4
  99. data/sorbet/rbi/annotations/.gitattributes +0 -1
  100. data/sorbet/rbi/annotations/activesupport.rbi +0 -453
  101. data/sorbet/rbi/annotations/faraday.rbi +0 -17
  102. data/sorbet/rbi/annotations/minitest.rbi +0 -119
  103. data/sorbet/rbi/annotations/mocha.rbi +0 -34
  104. data/sorbet/rbi/annotations/rainbow.rbi +0 -269
  105. data/sorbet/rbi/annotations/webmock.rbi +0 -9
  106. data/sorbet/rbi/dsl/.gitattributes +0 -1
  107. data/sorbet/rbi/dsl/active_support/callbacks.rbi +0 -23
  108. data/sorbet/rbi/gems/.gitattributes +0 -1
  109. data/sorbet/rbi/gems/activesupport@7.1.5.rbi +0 -18746
  110. data/sorbet/rbi/gems/addressable@2.8.6.rbi +0 -1994
  111. data/sorbet/rbi/gems/ansi@1.5.0.rbi +0 -688
  112. data/sorbet/rbi/gems/asana@0.10.6-ab9393136d9ca59b75e42a661fdddc1c65c8f7c3.rbi +0 -6142
  113. data/sorbet/rbi/gems/ast@2.4.2.rbi +0 -585
  114. data/sorbet/rbi/gems/backport@1.2.0.rbi +0 -523
  115. data/sorbet/rbi/gems/base64@0.2.0.rbi +0 -509
  116. data/sorbet/rbi/gems/benchmark@0.4.0.rbi +0 -618
  117. data/sorbet/rbi/gems/bigdecimal@3.1.5.rbi +0 -78
  118. data/sorbet/rbi/gems/brakeman@6.2.2.rbi +0 -222
  119. data/sorbet/rbi/gems/builder@3.2.4.rbi +0 -505
  120. data/sorbet/rbi/gems/bump@0.10.0.rbi +0 -169
  121. data/sorbet/rbi/gems/cache@0.4.1.rbi +0 -211
  122. data/sorbet/rbi/gems/cache_method@0.2.7.rbi +0 -293
  123. data/sorbet/rbi/gems/chef-utils@18.3.0.rbi +0 -9
  124. data/sorbet/rbi/gems/childprocess@5.1.0.rbi +0 -383
  125. data/sorbet/rbi/gems/coderay@1.1.3.rbi +0 -3427
  126. data/sorbet/rbi/gems/commander@4.6.0.rbi +0 -9
  127. data/sorbet/rbi/gems/concurrent-ruby@1.2.3.rbi +0 -11591
  128. data/sorbet/rbi/gems/connection_pool@2.4.1.rbi +0 -9
  129. data/sorbet/rbi/gems/crack@0.4.5.rbi +0 -145
  130. data/sorbet/rbi/gems/diff-lcs@1.5.1.rbi +0 -969
  131. data/sorbet/rbi/gems/docile@1.4.0.rbi +0 -377
  132. data/sorbet/rbi/gems/drb@2.2.1.rbi +0 -1347
  133. data/sorbet/rbi/gems/e2mmap@0.1.0.rbi +0 -9
  134. data/sorbet/rbi/gems/erubi@1.13.0.rbi +0 -152
  135. data/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi +0 -222
  136. data/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi +0 -126
  137. data/sorbet/rbi/gems/faraday-excon@1.1.0.rbi +0 -136
  138. data/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi +0 -145
  139. data/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi +0 -259
  140. data/sorbet/rbi/gems/faraday-net_http@1.0.1.rbi +0 -142
  141. data/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi +0 -118
  142. data/sorbet/rbi/gems/faraday-patron@1.0.0.rbi +0 -125
  143. data/sorbet/rbi/gems/faraday-rack@1.0.0.rbi +0 -133
  144. data/sorbet/rbi/gems/faraday-retry@1.0.3.rbi +0 -198
  145. data/sorbet/rbi/gems/faraday@1.10.3.rbi +0 -2729
  146. data/sorbet/rbi/gems/faraday_middleware-multi_json@0.0.6.rbi +0 -29
  147. data/sorbet/rbi/gems/faraday_middleware@1.2.0.rbi +0 -1004
  148. data/sorbet/rbi/gems/gli@2.22.0.rbi +0 -9
  149. data/sorbet/rbi/gems/hashdiff@1.0.1.rbi +0 -351
  150. data/sorbet/rbi/gems/highline@2.0.3.rbi +0 -9
  151. data/sorbet/rbi/gems/i18n@1.14.6.rbi +0 -2359
  152. data/sorbet/rbi/gems/imagen@0.1.8.rbi +0 -340
  153. data/sorbet/rbi/gems/iniparse@1.5.0.rbi +0 -899
  154. data/sorbet/rbi/gems/jaro_winkler@1.6.0.rbi +0 -22
  155. data/sorbet/rbi/gems/json@2.7.1.rbi +0 -1562
  156. data/sorbet/rbi/gems/jwt@2.7.1.rbi +0 -1405
  157. data/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi +0 -128
  158. data/sorbet/rbi/gems/kramdown@2.4.0.rbi +0 -3272
  159. data/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi +0 -14238
  160. data/sorbet/rbi/gems/logger@1.6.2.rbi +0 -923
  161. data/sorbet/rbi/gems/mdl@0.13.0.rbi +0 -445
  162. data/sorbet/rbi/gems/method_source@1.0.0.rbi +0 -273
  163. data/sorbet/rbi/gems/mime-types-data@3.2023.1205.rbi +0 -127
  164. data/sorbet/rbi/gems/mime-types@3.5.1.rbi +0 -1252
  165. data/sorbet/rbi/gems/minitest-profile@0.0.2.rbi +0 -136
  166. data/sorbet/rbi/gems/minitest-reporters@1.6.1.rbi +0 -1014
  167. data/sorbet/rbi/gems/minitest@5.21.1.rbi +0 -1539
  168. data/sorbet/rbi/gems/mixlib-cli@2.1.8.rbi +0 -314
  169. data/sorbet/rbi/gems/mixlib-config@3.0.27.rbi +0 -581
  170. data/sorbet/rbi/gems/mixlib-shellout@3.2.7.rbi +0 -629
  171. data/sorbet/rbi/gems/mocha@2.1.0.rbi +0 -12
  172. data/sorbet/rbi/gems/multi_json@1.15.0.rbi +0 -268
  173. data/sorbet/rbi/gems/multi_xml@0.6.0.rbi +0 -102
  174. data/sorbet/rbi/gems/multipart-post@2.3.0.rbi +0 -234
  175. data/sorbet/rbi/gems/mutex_m@0.3.0.rbi +0 -97
  176. data/sorbet/rbi/gems/netrc@0.11.0.rbi +0 -159
  177. data/sorbet/rbi/gems/nokogiri@1.17.0.rbi +0 -8201
  178. data/sorbet/rbi/gems/oauth2@1.4.11.rbi +0 -833
  179. data/sorbet/rbi/gems/overcommit@0.64.1.rbi +0 -2400
  180. data/sorbet/rbi/gems/parallel@1.23.0.rbi +0 -274
  181. data/sorbet/rbi/gems/parlour@5.0.0.rbi +0 -3007
  182. data/sorbet/rbi/gems/parser@3.2.2.4.rbi +0 -7253
  183. data/sorbet/rbi/gems/prism@1.2.0.rbi +0 -39085
  184. data/sorbet/rbi/gems/pry@0.14.2.rbi +0 -10070
  185. data/sorbet/rbi/gems/public_suffix@5.0.4.rbi +0 -936
  186. data/sorbet/rbi/gems/punchlist@1.3.2.rbi +0 -173
  187. data/sorbet/rbi/gems/racc@1.8.1.rbi +0 -162
  188. data/sorbet/rbi/gems/rack@3.1.8.rbi +0 -4896
  189. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +0 -403
  190. data/sorbet/rbi/gems/rake@13.1.0.rbi +0 -3022
  191. data/sorbet/rbi/gems/rbi@0.2.1.rbi +0 -4535
  192. data/sorbet/rbi/gems/rbs@2.8.4.rbi +0 -5613
  193. data/sorbet/rbi/gems/regexp_parser@2.8.3.rbi +0 -3750
  194. data/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi +0 -390
  195. data/sorbet/rbi/gems/rexml@3.3.9.rbi +0 -4964
  196. data/sorbet/rbi/gems/rubocop-ast@1.30.0.rbi +0 -7127
  197. data/sorbet/rbi/gems/rubocop-minitest@0.34.5.rbi +0 -2577
  198. data/sorbet/rbi/gems/rubocop-performance@1.20.2.rbi +0 -3262
  199. data/sorbet/rbi/gems/rubocop-rake@0.6.0.rbi +0 -329
  200. data/sorbet/rbi/gems/rubocop-rspec@3.0.0.rbi +0 -7546
  201. data/sorbet/rbi/gems/rubocop@1.59.0.rbi +0 -57238
  202. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +0 -1318
  203. data/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi +0 -9
  204. data/sorbet/rbi/gems/rugged@1.6.3.rbi +0 -1577
  205. data/sorbet/rbi/gems/securerandom@0.4.0.rbi +0 -75
  206. data/sorbet/rbi/gems/simplecov-html@0.12.3.rbi +0 -217
  207. data/sorbet/rbi/gems/simplecov-lcov@0.8.0.rbi +0 -256
  208. data/sorbet/rbi/gems/simplecov@0.22.0.rbi +0 -2149
  209. data/sorbet/rbi/gems/simplecov_json_formatter@0.1.4.rbi +0 -9
  210. data/sorbet/rbi/gems/solargraph-rails@1.1.0-9dc37915bd4f3b169046e34db6fb32193ab347d8.rbi +0 -320
  211. data/sorbet/rbi/gems/solargraph@0.50.1-904b9304770a59fac393c5cc3cad481e5bdf0fd8.rbi +0 -9396
  212. data/sorbet/rbi/gems/sord@5.1.0.rbi +0 -820
  213. data/sorbet/rbi/gems/source_finder@3.2.1.rbi +0 -317
  214. data/sorbet/rbi/gems/spoom@1.5.0.rbi +0 -4932
  215. data/sorbet/rbi/gems/tapioca@0.16.5.rbi +0 -3617
  216. data/sorbet/rbi/gems/thor@1.3.2.rbi +0 -4378
  217. data/sorbet/rbi/gems/tilt@2.4.0.rbi +0 -933
  218. data/sorbet/rbi/gems/tomlrb@2.0.3.rbi +0 -9
  219. data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +0 -5918
  220. data/sorbet/rbi/gems/undercover@0.5.0.rbi +0 -433
  221. data/sorbet/rbi/gems/unicode-display_width@2.5.0.rbi +0 -66
  222. data/sorbet/rbi/gems/webmock@3.19.1.rbi +0 -1769
  223. data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +0 -435
  224. data/sorbet/rbi/gems/yard@0.9.37.rbi +0 -18406
  225. data/sorbet/rbi/todo.rbi +0 -11
  226. data/sorbet/tapioca/config.yml +0 -13
  227. data/sorbet/tapioca/require.rb +0 -4
@@ -1,523 +0,0 @@
1
- # typed: strict
2
-
3
- # DO NOT EDIT MANUALLY
4
- # This is an autogenerated file for types exported from the `backport` gem.
5
- # Please instead update this file by running `bin/tapioca gem backport`.
6
-
7
-
8
- # An event-driven IO library.
9
- #
10
- # source://backport//lib/backport/version.rb#1
11
- module Backport
12
- class << self
13
- # @return [Logger]
14
- #
15
- # source://backport//lib/backport.rb#75
16
- def logger; end
17
-
18
- # Prepare an interval server to run in Backport.
19
- #
20
- # @param period [Float] Seconds between intervals
21
- # @return [void]
22
- #
23
- # source://backport//lib/backport.rb#35
24
- def prepare_interval(period, &block); end
25
-
26
- # Prepare a STDIO server to run in Backport.
27
- #
28
- # @param adapter [Adapter]
29
- # @return [void]
30
- #
31
- # source://backport//lib/backport.rb#17
32
- def prepare_stdio_server(adapter: T.unsafe(nil)); end
33
-
34
- # Prepare a TCP server to run in Backport.
35
- #
36
- # @param host [String]
37
- # @param port [Integer]
38
- # @param adapter [Adapter]
39
- # @return [void]
40
- #
41
- # source://backport//lib/backport.rb#27
42
- def prepare_tcp_server(host: T.unsafe(nil), port: T.unsafe(nil), adapter: T.unsafe(nil)); end
43
-
44
- # Run the Backport machine. The provided block will be executed before the
45
- # machine starts. Program execution is blocked until the machine stops.
46
- #
47
- # @example Print "tick" once per second
48
- # Backport.run do
49
- # Backport.prepare_interval 1 do
50
- # puts "tick"
51
- # end
52
- # end
53
- # @return [void]
54
- #
55
- # source://backport//lib/backport.rb#50
56
- def run(&block); end
57
-
58
- # Stop all running Backport machines.
59
- #
60
- # For more accurate control, consider stopping the machine
61
- # from the self reference in Machine#run, e.g.:
62
- #
63
- # ```
64
- # Backport.run do |machine|
65
- # # ...
66
- # machine.stop
67
- # end
68
- # ```
69
- #
70
- # @return [void]
71
- #
72
- # source://backport//lib/backport.rb#70
73
- def stop; end
74
-
75
- private
76
-
77
- # @return [Array<Machine>]
78
- #
79
- # source://backport//lib/backport.rb#82
80
- def machines; end
81
- end
82
- end
83
-
84
- # The application interface between Backport servers and clients.
85
- #
86
- # source://backport//lib/backport/adapter.rb#4
87
- class Backport::Adapter
88
- # @param output [IO]
89
- # @param remote [Hash{Symbol => String, Integer}]
90
- # @return [Adapter] a new instance of Adapter
91
- #
92
- # source://backport//lib/backport/adapter.rb#7
93
- def initialize(output, remote = T.unsafe(nil)); end
94
-
95
- # Close the client connection.
96
- #
97
- # @note The adapter sets #closed? to true and runs the #closing callback.
98
- # The server is responsible for implementation details like closing the
99
- # client's socket.
100
- # @return [void]
101
- #
102
- # source://backport//lib/backport/adapter.rb#80
103
- def close; end
104
-
105
- # @return [Boolean]
106
- #
107
- # source://backport//lib/backport/adapter.rb#69
108
- def closed?; end
109
-
110
- # A callback triggered when a client connection is closing. Subclasses
111
- # and/or modules should override this method to provide their own
112
- # functionality.
113
- #
114
- # @return [void]
115
- #
116
- # source://backport//lib/backport/adapter.rb#41
117
- def closing; end
118
-
119
- # A callback triggered when a client connection is opening. Subclasses
120
- # and/or modules should override this method to provide their own
121
- # functionality.
122
- #
123
- # @return [void]
124
- #
125
- # source://backport//lib/backport/adapter.rb#34
126
- def opening; end
127
-
128
- # A callback triggered when the server receives data from the client.
129
- # Subclasses and/or modules should override this method to provide their
130
- # own functionality.
131
- #
132
- # @param data [String]
133
- # @return [void]
134
- #
135
- # source://backport//lib/backport/adapter.rb#49
136
- def receiving(data); end
137
-
138
- # A hash of information about the client connection. The data can vary
139
- # based on the transport, e.g., :hostname and :address for TCP connections
140
- # or :filename for file streams.
141
- #
142
- # @return [Hash{Symbol => String, Integer}]
143
- #
144
- # source://backport//lib/backport/adapter.rb#25
145
- def remote; end
146
-
147
- # Send data to the client.
148
- #
149
- # @param data [String]
150
- # @return [void]
151
- #
152
- # source://backport//lib/backport/adapter.rb#55
153
- def write(data); end
154
-
155
- # Send a line of data to the client.
156
- #
157
- # @param data [String]
158
- # @return [void]
159
- #
160
- # source://backport//lib/backport/adapter.rb#64
161
- def write_line(data); end
162
- end
163
-
164
- # A client connected to a connectable Backport server.
165
- #
166
- # source://backport//lib/backport/client.rb#6
167
- class Backport::Client
168
- include ::Observable
169
-
170
- # @param input [IO]
171
- # @param output [IO]
172
- # @param adapter [Class, Module]
173
- # @param remote [Hash]
174
- # @return [Client] a new instance of Client
175
- #
176
- # source://backport//lib/backport/client.rb#16
177
- def initialize(input, output, adapter, remote = T.unsafe(nil)); end
178
-
179
- # @return [Adapter]
180
- #
181
- # source://backport//lib/backport/client.rb#10
182
- def adapter; end
183
-
184
- # Start running the client. This method will start the thread that reads
185
- # client input from IO.
186
- #
187
- # @deprecated Prefer #start to #run for non-blocking client/server methods
188
- # @return [void]
189
- #
190
- # source://backport//lib/backport/client.rb#50
191
- def run; end
192
-
193
- # Start running the client. This method will start the thread that reads
194
- # client input from IO.
195
- #
196
- # @return [void]
197
- #
198
- # source://backport//lib/backport/client.rb#50
199
- def start; end
200
-
201
- # Close the client connection.
202
- #
203
- # callback. The server is responsible for implementation details like
204
- # closing the client's socket.
205
- #
206
- # @note The client sets #stopped? to true and runs the adapter's #closing
207
- # @return [void]
208
- #
209
- # source://backport//lib/backport/client.rb#38
210
- def stop; end
211
-
212
- # True if the client is stopped.
213
- #
214
- # @return [Boolean]
215
- #
216
- # source://backport//lib/backport/client.rb#27
217
- def stopped?; end
218
-
219
- # Handle a tick from the server. This method will check for client input
220
- # and update the adapter accordingly, or stop the client if the adapter is
221
- # closed.
222
- #
223
- # @return [void]
224
- #
225
- # source://backport//lib/backport/client.rb#64
226
- def tick; end
227
-
228
- private
229
-
230
- # @param mod_cls [Module, Class] The Adapter module or class
231
- # @param remote [Hash] Remote client data
232
- # @return [Adapter]
233
- #
234
- # source://backport//lib/backport/client.rb#86
235
- def make_adapter(mod_cls, remote); end
236
-
237
- # @return [Mutex]
238
- #
239
- # source://backport//lib/backport/client.rb#98
240
- def mutex; end
241
-
242
- # Read the client input. Return nil if the input buffer is empty.
243
- #
244
- # @return [String, nil]
245
- #
246
- # source://backport//lib/backport/client.rb#74
247
- def read; end
248
-
249
- # Read input from the client.
250
- #
251
- # @return [void]
252
- #
253
- # source://backport//lib/backport/client.rb#112
254
- def read_input; end
255
-
256
- # Start the thread that checks the input IO for client data.
257
- #
258
- # @return [void]
259
- #
260
- # source://backport//lib/backport/client.rb#103
261
- def run_input_thread; end
262
- end
263
-
264
- # The Backport server controller.
265
- #
266
- # source://backport//lib/backport/machine.rb#4
267
- class Backport::Machine
268
- # @return [Machine] a new instance of Machine
269
- #
270
- # source://backport//lib/backport/machine.rb#5
271
- def initialize; end
272
-
273
- # Add a server to the machine. The server will be started when the machine
274
- # starts. If the machine is already running, the server will be started
275
- # immediately.
276
- #
277
- # @param server [Server::Base]
278
- # @return [void]
279
- #
280
- # source://backport//lib/backport/machine.rb#45
281
- def prepare(server); end
282
-
283
- # Run the machine. If a block is provided, it gets executed before the
284
- # maching starts its main loop. The main loop blocks program execution
285
- # until the machine is stopped.
286
- #
287
- # @return [void]
288
- # @yieldparam [self]
289
- #
290
- # source://backport//lib/backport/machine.rb#16
291
- def run; end
292
-
293
- # @return [Array<Server::Base>]
294
- #
295
- # source://backport//lib/backport/machine.rb#52
296
- def servers; end
297
-
298
- # Stop the machine.
299
- #
300
- # @return [void]
301
- #
302
- # source://backport//lib/backport/machine.rb#27
303
- def stop; end
304
-
305
- # True if the machine is stopped.
306
- #
307
- # @return [Boolean]
308
- #
309
- # source://backport//lib/backport/machine.rb#35
310
- def stopped?; end
311
-
312
- # @param server [Server::Base]
313
- # @return [void]
314
- #
315
- # source://backport//lib/backport/machine.rb#58
316
- def update(server); end
317
-
318
- private
319
-
320
- # @return [Mutex]
321
- #
322
- # source://backport//lib/backport/machine.rb#70
323
- def mutex; end
324
-
325
- # Start the thread that updates servers via the #tick method.
326
- #
327
- # @return [void]
328
- #
329
- # source://backport//lib/backport/machine.rb#75
330
- def run_server_thread; end
331
- end
332
-
333
- # Classes and modules for Backport servers.
334
- #
335
- # source://backport//lib/backport/server.rb#4
336
- module Backport::Server; end
337
-
338
- # An extendable server class that provides basic start/stop functionality
339
- # and common callbacks.
340
- #
341
- # source://backport//lib/backport/server/base.rb#8
342
- class Backport::Server::Base
343
- include ::Observable
344
-
345
- # Start the server.
346
- #
347
- # @return [void]
348
- #
349
- # source://backport//lib/backport/server/base.rb#14
350
- def start; end
351
-
352
- # @return [Boolean]
353
- #
354
- # source://backport//lib/backport/server/base.rb#31
355
- def started?; end
356
-
357
- # A callback triggered when a Machine starts running or the server is
358
- # added to a running machine. Subclasses should override this method to
359
- # provide their own functionality.
360
- #
361
- # @return [void]
362
- #
363
- # source://backport//lib/backport/server/base.rb#44
364
- def starting; end
365
-
366
- # Stop the server.
367
- #
368
- # @return [void]
369
- #
370
- # source://backport//lib/backport/server/base.rb#23
371
- def stop; end
372
-
373
- # @return [Boolean]
374
- #
375
- # source://backport//lib/backport/server/base.rb#35
376
- def stopped?; end
377
-
378
- # A callback triggered when the server is stopping. Subclasses should
379
- # override this method to provide their own functionality.
380
- #
381
- # @return [void]
382
- #
383
- # source://backport//lib/backport/server/base.rb#50
384
- def stopping; end
385
-
386
- # A callback triggered from the main loop of a running Machine.
387
- # Subclasses should override this method to provide their own
388
- # functionality.
389
- #
390
- # @return [void]
391
- #
392
- # source://backport//lib/backport/server/base.rb#57
393
- def tick; end
394
- end
395
-
396
- # A mixin for Backport servers that communicate with clients.
397
- #
398
- # Connectable servers check clients for incoming data on each tick.
399
- #
400
- # source://backport//lib/backport/server/connectable.rb#7
401
- module Backport::Server::Connectable
402
- # @return [Array<Client>]
403
- #
404
- # source://backport//lib/backport/server/connectable.rb#19
405
- def clients; end
406
-
407
- # @return [void]
408
- #
409
- # source://backport//lib/backport/server/connectable.rb#9
410
- def starting; end
411
-
412
- # @return [void]
413
- #
414
- # source://backport//lib/backport/server/connectable.rb#14
415
- def stopping; end
416
-
417
- private
418
-
419
- # @return [Mutex]
420
- #
421
- # source://backport//lib/backport/server/connectable.rb#26
422
- def mutex; end
423
- end
424
-
425
- # A Backport periodical interval server.
426
- #
427
- # source://backport//lib/backport/server/interval.rb#8
428
- class Backport::Server::Interval < ::Backport::Server::Base
429
- # @param period [Float] The interval time in seconds.
430
- # @param block [Proc] The proc to run on each interval.
431
- # @return [Interval] a new instance of Interval
432
- # @yieldparam [Interval]
433
- #
434
- # source://backport//lib/backport/server/interval.rb#9
435
- def initialize(period, &block); end
436
-
437
- # source://backport//lib/backport/server/interval.rb#16
438
- def starting; end
439
-
440
- # source://backport//lib/backport/server/interval.rb#21
441
- def tick; end
442
-
443
- private
444
-
445
- # @return [void]
446
- #
447
- # source://backport//lib/backport/server/interval.rb#32
448
- def run_ready_thread; end
449
- end
450
-
451
- # A Backport STDIO server.
452
- #
453
- # source://backport//lib/backport/server/stdio.rb#5
454
- class Backport::Server::Stdio < ::Backport::Server::Base
455
- include ::Backport::Server::Connectable
456
-
457
- # @param input [IO]
458
- # @param output [IO]
459
- # @param adapter [Module, Class]
460
- # @return [Stdio] a new instance of Stdio
461
- #
462
- # source://backport//lib/backport/server/stdio.rb#11
463
- def initialize(input: T.unsafe(nil), output: T.unsafe(nil), adapter: T.unsafe(nil)); end
464
-
465
- # @param client [Client]
466
- # @return [void]
467
- #
468
- # source://backport//lib/backport/server/stdio.rb#22
469
- def update(client); end
470
- end
471
-
472
- # A Backport TCP server. It runs a thread to accept incoming connections
473
- # and automatically stops when the socket is closed.
474
- #
475
- # source://backport//lib/backport/server/tcpip.rb#8
476
- class Backport::Server::Tcpip < ::Backport::Server::Base
477
- include ::Backport::Server::Connectable
478
-
479
- # @param host [String]
480
- # @param port [Integer]
481
- # @param adapter [Module, Class]
482
- # @param socket_class [Class]
483
- # @return [Tcpip] a new instance of Tcpip
484
- #
485
- # source://backport//lib/backport/server/tcpip.rb#15
486
- def initialize(host: T.unsafe(nil), port: T.unsafe(nil), adapter: T.unsafe(nil), socket_class: T.unsafe(nil)); end
487
-
488
- # Accept an incoming connection using accept_nonblock. Return the
489
- # resulting Client if a connection was accepted or nil if no connections
490
- # are pending.
491
- #
492
- # @return [Client, nil]
493
- #
494
- # source://backport//lib/backport/server/tcpip.rb#41
495
- def accept; end
496
-
497
- # source://backport//lib/backport/server/tcpip.rb#21
498
- def starting; end
499
-
500
- # source://backport//lib/backport/server/tcpip.rb#25
501
- def stopping; end
502
-
503
- # @param client [Client]
504
- # @return [void]
505
- #
506
- # source://backport//lib/backport/server/tcpip.rb#78
507
- def update(client); end
508
-
509
- private
510
-
511
- # @return [TCPSocket]
512
- #
513
- # source://backport//lib/backport/server/tcpip.rb#89
514
- def socket; end
515
-
516
- # @return [void]
517
- #
518
- # source://backport//lib/backport/server/tcpip.rb#92
519
- def start_accept_thread; end
520
- end
521
-
522
- # source://backport//lib/backport/version.rb#2
523
- Backport::VERSION = T.let(T.unsafe(nil), String)